Package org.eclipse.tycho.p2.target
Class TargetPlatformBaseImpl
- java.lang.Object
-
- org.eclipse.tycho.p2.target.TargetPlatformBaseImpl
-
- All Implemented Interfaces:
TargetPlatform
,P2TargetPlatform
- Direct Known Subclasses:
FinalTargetPlatformImpl
,PreliminaryTargetPlatformImpl
abstract class TargetPlatformBaseImpl extends java.lang.Object implements P2TargetPlatform
-
-
Field Summary
Fields Modifier and Type Field Description (package private) IRawArtifactFileProvider
artifacts
(package private) ExecutionEnvironmentResolutionHints
executionEnvironment
Execution environment information with information about the packages provided by the JRE.protected java.util.LinkedHashSet<org.eclipse.equinox.p2.metadata.IInstallableUnit>
installableUnits
All installable units contained in the target platform.private LocalArtifactRepository
localArtifactRepository
Deprecated.(package private) java.util.Map<org.eclipse.equinox.p2.metadata.IInstallableUnit,IArtifactFacade>
mavenArtifactLookup
Map from installable units back to the contributing artifacts.private java.util.Map<org.eclipse.equinox.p2.metadata.IInstallableUnit,ReactorProjectIdentities>
reactorProjectLookup
Map from installable units back to the contributing reactor project.-
Fields inherited from interface org.eclipse.tycho.artifacts.TargetPlatform
FINAL_TARGET_PLATFORM_KEY
-
-
Constructor Summary
Constructors Constructor Description TargetPlatformBaseImpl(java.util.LinkedHashSet<org.eclipse.equinox.p2.metadata.IInstallableUnit> installableUnits, ExecutionEnvironmentResolutionHints executionEnvironment, IRawArtifactFileProvider artifacts, LocalArtifactRepository localArtifactRepository, java.util.Map<org.eclipse.equinox.p2.metadata.IInstallableUnit,ReactorProjectIdentities> reactorProjectLookup, java.util.Map<org.eclipse.equinox.p2.metadata.IInstallableUnit,IArtifactFacade> mavenArtifactLookup)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ExecutionEnvironmentResolutionHints
getEEResolutionHints()
Returns additional information for resolving against the configured execution environment.java.util.Set<org.eclipse.equinox.p2.metadata.IInstallableUnit>
getInstallableUnits()
java.io.File
getLocalArtifactFile(org.eclipse.equinox.p2.metadata.IArtifactKey key)
java.util.Map<org.eclipse.equinox.p2.metadata.IInstallableUnit,IArtifactFacade>
getOriginalMavenArtifactMap()
Returns the map from target platform installable units back to the contributing Maven artifacts.java.util.Map<org.eclipse.equinox.p2.metadata.IInstallableUnit,ReactorProjectIdentities>
getOriginalReactorProjectMap()
Returns the map from target platform installable units back to the contributing reactor project.ArtifactKey
resolveArtifact(java.lang.String type, java.lang.String id, java.lang.String version)
Returns an artifact of the given type, id and matching version.org.eclipse.equinox.p2.metadata.IInstallableUnit
resolveUnit(java.lang.String type, java.lang.String id, org.eclipse.equinox.p2.metadata.Version version)
Same asTargetPlatform.resolveArtifact(String, String, String)
but returning the result asIInstallableUnit
.void
saveLocalMavenRepository()
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.eclipse.tycho.p2.target.P2TargetPlatform
getInstallableUnitsAsMetadataRepository, reportUsedLocalIUs
-
Methods inherited from interface org.eclipse.tycho.artifacts.TargetPlatform
getArtifactLocation
-
-
-
-
Field Detail
-
installableUnits
protected final java.util.LinkedHashSet<org.eclipse.equinox.p2.metadata.IInstallableUnit> installableUnits
All installable units contained in the target platform. This includes reactor-external content and all results of upstream reactor projects (or all projects in case of the preliminary target platform where the reactor build order isn't known yet). Configured and automatic filters have been applied.
-
reactorProjectLookup
private final java.util.Map<org.eclipse.equinox.p2.metadata.IInstallableUnit,ReactorProjectIdentities> reactorProjectLookup
Map from installable units back to the contributing reactor project. Note: May contain installable units as keys which are not part of the target platform.
-
mavenArtifactLookup
final java.util.Map<org.eclipse.equinox.p2.metadata.IInstallableUnit,IArtifactFacade> mavenArtifactLookup
Map from installable units back to the contributing artifacts. Note: May contain installable units as keys which are not part of the target platform.
-
executionEnvironment
final ExecutionEnvironmentResolutionHints executionEnvironment
Execution environment information with information about the packages provided by the JRE.
-
artifacts
final IRawArtifactFileProvider artifacts
-
localArtifactRepository
@Deprecated private LocalArtifactRepository localArtifactRepository
Deprecated.
-
-
Constructor Detail
-
TargetPlatformBaseImpl
public TargetPlatformBaseImpl(java.util.LinkedHashSet<org.eclipse.equinox.p2.metadata.IInstallableUnit> installableUnits, ExecutionEnvironmentResolutionHints executionEnvironment, IRawArtifactFileProvider artifacts, LocalArtifactRepository localArtifactRepository, java.util.Map<org.eclipse.equinox.p2.metadata.IInstallableUnit,ReactorProjectIdentities> reactorProjectLookup, java.util.Map<org.eclipse.equinox.p2.metadata.IInstallableUnit,IArtifactFacade> mavenArtifactLookup)
-
-
Method Detail
-
getInstallableUnits
public final java.util.Set<org.eclipse.equinox.p2.metadata.IInstallableUnit> getInstallableUnits()
- Specified by:
getInstallableUnits
in interfaceP2TargetPlatform
-
resolveArtifact
public final ArtifactKey resolveArtifact(java.lang.String type, java.lang.String id, java.lang.String version) throws IllegalArtifactReferenceException, DependencyResolutionException
Description copied from interface:TargetPlatform
Returns an artifact of the given type, id and matching version. The version reference string matches versions according to the following rules:- "0.0.0" or
null
matches any version - "1.2.3.qualifier", i.e. a version with a literal "qualifier", matches all versions in the range [1.2.3,1.2.4)
- all other version references match artifacts with exactly that version. For example the version reference "1.2.3.v2014" stands for the strict version range [1.2.3.v2014,1.2.3.v2014]
- Specified by:
resolveArtifact
in interfaceTargetPlatform
- Parameters:
type
- One of the types defined inArtifactType
id
- The ID of the artifact to be found.version
- A version reference string selecting one exact version or versions from a range. May benull
.- Returns:
- a matching artifact.
- Throws:
IllegalArtifactReferenceException
- if an invalid type or malformed version reference is givenDependencyResolutionException
- if there is no matching artifact in the target platform.
- "0.0.0" or
-
resolveUnit
public final org.eclipse.equinox.p2.metadata.IInstallableUnit resolveUnit(java.lang.String type, java.lang.String id, org.eclipse.equinox.p2.metadata.Version version) throws IllegalArtifactReferenceException, DependencyResolutionException
Description copied from interface:P2TargetPlatform
Same asTargetPlatform.resolveArtifact(String, String, String)
but returning the result asIInstallableUnit
. Note: "artifact" in "resolveArtifact" refers to a Tycho artifact, which technically represent a p2 installable unit and optionally the associated p2 artifact.- Specified by:
resolveUnit
in interfaceP2TargetPlatform
- Throws:
IllegalArtifactReferenceException
DependencyResolutionException
-
getEEResolutionHints
public final ExecutionEnvironmentResolutionHints getEEResolutionHints()
Description copied from interface:P2TargetPlatform
Returns additional information for resolving against the configured execution environment.- Specified by:
getEEResolutionHints
in interfaceP2TargetPlatform
-
getOriginalReactorProjectMap
public final java.util.Map<org.eclipse.equinox.p2.metadata.IInstallableUnit,ReactorProjectIdentities> getOriginalReactorProjectMap()
Description copied from interface:P2TargetPlatform
Returns the map from target platform installable units back to the contributing reactor project.Note: The map may contain additional installable units as keys, i.e. not all keys are necessarily part of the target platform.
- Specified by:
getOriginalReactorProjectMap
in interfaceP2TargetPlatform
-
getOriginalMavenArtifactMap
public final java.util.Map<org.eclipse.equinox.p2.metadata.IInstallableUnit,IArtifactFacade> getOriginalMavenArtifactMap()
Description copied from interface:P2TargetPlatform
Returns the map from target platform installable units back to the contributing Maven artifacts.Note: The map may contain additional installable units as keys, i.e. not all keys are necessarily part of the target platform.
- Specified by:
getOriginalMavenArtifactMap
in interfaceP2TargetPlatform
-
getLocalArtifactFile
public final java.io.File getLocalArtifactFile(org.eclipse.equinox.p2.metadata.IArtifactKey key)
- Specified by:
getLocalArtifactFile
in interfaceP2TargetPlatform
-
saveLocalMavenRepository
public final void saveLocalMavenRepository()
- Specified by:
saveLocalMavenRepository
in interfaceP2TargetPlatform
-
-