Package org.eclipse.tycho.pomless
Class TychoBundleMapping
- java.lang.Object
-
- org.eclipse.tycho.pomless.AbstractTychoMapping
-
- org.eclipse.tycho.pomless.TychoBundleMapping
-
- All Implemented Interfaces:
org.apache.maven.model.io.ModelReader
,org.sonatype.maven.polyglot.mapping.Mapping
@Component(role=org.sonatype.maven.polyglot.mapping.Mapping.class, hint="eclipse-plugin") public class TychoBundleMapping extends AbstractTychoMapping
-
-
Field Summary
Fields Modifier and Type Field Description private static java.lang.String
BUNDLE_SYMBOLIC_NAME
private static java.lang.String
MANIFEST_MF
static java.lang.String
MANIFEST_MF_MARKER
static java.lang.String
PACKAGING
private static java.lang.String
PACKAGING_TEST
-
Fields inherited from class org.eclipse.tycho.pomless.AbstractTychoMapping
container, logger
-
-
Constructor Summary
Constructors Constructor Description TychoBundleMapping()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description private java.lang.String
getBundleSymbolicName(java.util.jar.Attributes headers, java.io.File manifestFile)
private static java.lang.String
getManifestAttributeValue(java.util.jar.Attributes headers, java.lang.String attributeName, java.io.File manifestFile)
protected java.lang.String
getPackaging()
protected java.io.File
getPrimaryArtifact(java.io.File dir)
protected java.io.File
getRealArtifactFile(java.io.File polyglotArtifactFile)
private java.lang.String
getRequiredHeaderValue(java.lang.String headerKey, java.util.jar.Attributes headers, java.io.File manifestFile)
protected void
initModel(org.apache.maven.model.Model model, java.io.Reader artifactReader, java.io.File artifactFile)
private boolean
isTestBundle(java.lang.String bundleSymbolicName, java.util.jar.Attributes manifestHeaders, java.io.File bundleRoot)
protected boolean
isValidLocation(java.lang.String location)
private java.util.jar.Attributes
readManifestHeaders(java.io.File manifestFile)
-
Methods inherited from class org.eclipse.tycho.pomless.AbstractTychoMapping
accept, findParent, getBuildProperties, getFlavour, getPomVersion, getPrimaryArtifactCharset, getPriority, getReader, getWriter, locatePom, locatePomReference, read, read, read
-
-
-
-
Field Detail
-
BUNDLE_SYMBOLIC_NAME
private static final java.lang.String BUNDLE_SYMBOLIC_NAME
- See Also:
- Constant Field Values
-
PACKAGING
public static final java.lang.String PACKAGING
- See Also:
- Constant Field Values
-
PACKAGING_TEST
private static final java.lang.String PACKAGING_TEST
- See Also:
- Constant Field Values
-
MANIFEST_MF
private static final java.lang.String MANIFEST_MF
- See Also:
- Constant Field Values
-
MANIFEST_MF_MARKER
public static final java.lang.String MANIFEST_MF_MARKER
- See Also:
- Constant Field Values
-
-
Method Detail
-
isValidLocation
protected boolean isValidLocation(java.lang.String location)
- Specified by:
isValidLocation
in classAbstractTychoMapping
-
getPrimaryArtifact
protected java.io.File getPrimaryArtifact(java.io.File dir)
- Specified by:
getPrimaryArtifact
in classAbstractTychoMapping
-
getPackaging
protected java.lang.String getPackaging()
- Specified by:
getPackaging
in classAbstractTychoMapping
-
initModel
protected void initModel(org.apache.maven.model.Model model, java.io.Reader artifactReader, java.io.File artifactFile) throws org.apache.maven.model.io.ModelParseException, java.io.IOException
- Specified by:
initModel
in classAbstractTychoMapping
- Throws:
org.apache.maven.model.io.ModelParseException
java.io.IOException
-
getRealArtifactFile
protected java.io.File getRealArtifactFile(java.io.File polyglotArtifactFile)
- Overrides:
getRealArtifactFile
in classAbstractTychoMapping
-
readManifestHeaders
private java.util.jar.Attributes readManifestHeaders(java.io.File manifestFile) throws java.io.IOException
- Throws:
java.io.IOException
-
getBundleSymbolicName
private java.lang.String getBundleSymbolicName(java.util.jar.Attributes headers, java.io.File manifestFile) throws org.apache.maven.model.io.ModelParseException
- Throws:
org.apache.maven.model.io.ModelParseException
-
getRequiredHeaderValue
private java.lang.String getRequiredHeaderValue(java.lang.String headerKey, java.util.jar.Attributes headers, java.io.File manifestFile) throws org.apache.maven.model.io.ModelParseException
- Throws:
org.apache.maven.model.io.ModelParseException
-
isTestBundle
private boolean isTestBundle(java.lang.String bundleSymbolicName, java.util.jar.Attributes manifestHeaders, java.io.File bundleRoot) throws java.io.IOException
- Throws:
java.io.IOException
-
getManifestAttributeValue
private static java.lang.String getManifestAttributeValue(java.util.jar.Attributes headers, java.lang.String attributeName, java.io.File manifestFile) throws java.io.IOException
- Throws:
java.io.IOException
-
-