Package org.eclipse.tycho.core.osgitools
Class DefaultArtifactDescriptor
- java.lang.Object
-
- org.eclipse.tycho.core.osgitools.DefaultArtifactDescriptor
-
- All Implemented Interfaces:
ArtifactDescriptor
- Direct Known Subclasses:
DefaultFeatureDescription
,DefaultPluginDescription
public class DefaultArtifactDescriptor extends java.lang.Object implements ArtifactDescriptor
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.String
classifier
private java.util.Set<java.lang.Object>
installableUnits
private ArtifactKey
key
private java.io.File
location
private java.util.function.Function<ArtifactDescriptor,java.io.File>
locationSupplier
private ReactorProject
project
-
Constructor Summary
Constructors Constructor Description DefaultArtifactDescriptor(ArtifactKey key, java.io.File location, ReactorProject project, java.lang.String classifier, java.util.Set<java.lang.Object> installableUnits)
DefaultArtifactDescriptor(ArtifactKey key, java.util.function.Function<ArtifactDescriptor,java.io.File> location, ReactorProject project, java.lang.String classifier, java.util.Set<java.lang.Object> installableUnits)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object obj)
java.lang.String
getClassifier()
Maven artifact classifier.java.util.Set<java.lang.Object>
getInstallableUnits()
P2 metadata describing the projectArtifactKey
getKey()
Eclipse/OSGi artifact key (a.k.a.java.io.File
getLocation(boolean fetch)
Artifact location on local filesystemReactorProject
getMavenProject()
ReactorProject corresponding to the artifact or null if the artifact does not come from a reactor project.int
hashCode()
java.lang.String
toString()
-
-
-
Field Detail
-
key
private final ArtifactKey key
-
locationSupplier
private java.util.function.Function<ArtifactDescriptor,java.io.File> locationSupplier
-
location
private java.io.File location
-
project
private final ReactorProject project
-
classifier
private final java.lang.String classifier
-
installableUnits
private final java.util.Set<java.lang.Object> installableUnits
-
-
Constructor Detail
-
DefaultArtifactDescriptor
public DefaultArtifactDescriptor(ArtifactKey key, java.io.File location, ReactorProject project, java.lang.String classifier, java.util.Set<java.lang.Object> installableUnits)
-
DefaultArtifactDescriptor
public DefaultArtifactDescriptor(ArtifactKey key, java.util.function.Function<ArtifactDescriptor,java.io.File> location, ReactorProject project, java.lang.String classifier, java.util.Set<java.lang.Object> installableUnits)
-
-
Method Detail
-
getKey
public ArtifactKey getKey()
Description copied from interface:ArtifactDescriptor
Eclipse/OSGi artifact key (a.k.a. "coordinates") that uniquely identify the artifact- Specified by:
getKey
in interfaceArtifactDescriptor
-
getLocation
public java.io.File getLocation(boolean fetch)
Description copied from interface:ArtifactDescriptor
Artifact location on local filesystem- Specified by:
getLocation
in interfaceArtifactDescriptor
- Parameters:
fetch
- whether to fetch artifact if not already available locally- Returns:
- the artifact location if already available or if
fetch=true
and fetching succeds;null
otherwise.
-
getMavenProject
public ReactorProject getMavenProject()
Description copied from interface:ArtifactDescriptor
ReactorProject corresponding to the artifact or null if the artifact does not come from a reactor project.- Specified by:
getMavenProject
in interfaceArtifactDescriptor
-
getClassifier
public java.lang.String getClassifier()
Description copied from interface:ArtifactDescriptor
Maven artifact classifier. Not null only for classified artifacts coming from a reactor project (eg, sources jar).- Specified by:
getClassifier
in interfaceArtifactDescriptor
-
getInstallableUnits
public java.util.Set<java.lang.Object> getInstallableUnits()
Description copied from interface:ArtifactDescriptor
P2 metadata describing the project- Specified by:
getInstallableUnits
in interfaceArtifactDescriptor
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
-
-