Package org.apache.ivy.osgi.core
Class OSGiManifestParser
java.lang.Object
org.apache.ivy.osgi.core.OSGiManifestParser
- All Implemented Interfaces:
ModuleDescriptorParser
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
void
static OSGiManifestParser
getMetadataArtifact
(ModuleRevisionId mrid, Resource res) Returns the module metadata artifact corresponding to the given module revision id that this parser parsesgetType()
Return the 'type' of module artifacts this parser is parsingparseDescriptor
(ParserSettings ivySettings, URL descriptorURL, boolean validate) parseDescriptor
(ParserSettings ivySettings, URL descriptorURL, Resource res, boolean validate) void
toIvyFile
(InputStream is, Resource res, File destFile, ModuleDescriptor md) Convert a module descriptor to an ivy file.toString()
-
Constructor Details
-
OSGiManifestParser
public OSGiManifestParser()
-
-
Method Details
-
getInstance
-
add
-
accept
- Specified by:
accept
in interfaceModuleDescriptorParser
-
parseDescriptor
public ModuleDescriptor parseDescriptor(ParserSettings ivySettings, URL descriptorURL, Resource res, boolean validate) throws ParseException, IOException - Specified by:
parseDescriptor
in interfaceModuleDescriptorParser
- Throws:
ParseException
IOException
-
toIvyFile
public void toIvyFile(InputStream is, Resource res, File destFile, ModuleDescriptor md) throws ParseException, IOException Description copied from interface:ModuleDescriptorParser
Convert a module descriptor to an ivy file. This method MUST close the given input stream when job is finished- Specified by:
toIvyFile
in interfaceModuleDescriptorParser
- Parameters:
is
- input stream with opened on original module descriptor resourceres
- ResourcedestFile
- Filemd
- ModuleDescriptor- Throws:
ParseException
- if something goes wrongIOException
- if something goes wrong
-
parseDescriptor
public ModuleDescriptor parseDescriptor(ParserSettings ivySettings, URL descriptorURL, boolean validate) throws ParseException, IOException - Specified by:
parseDescriptor
in interfaceModuleDescriptorParser
- Throws:
ParseException
IOException
-
getType
Description copied from interface:ModuleDescriptorParser
Return the 'type' of module artifacts this parser is parsing- Specified by:
getType
in interfaceModuleDescriptorParser
- Returns:
- the 'type' of module artifacts this parser is parsing
-
getMetadataArtifact
Description copied from interface:ModuleDescriptorParser
Returns the module metadata artifact corresponding to the given module revision id that this parser parses- Specified by:
getMetadataArtifact
in interfaceModuleDescriptorParser
- Parameters:
mrid
- the module revision id for which the module artifact should be returnedres
- the resource for which the module artifact should be returned- Returns:
- the module artifact corresponding to the given mrid and resource
-
toString
-