Class TestDependencyCollectionContext
- java.lang.Object
-
- org.eclipse.aether.internal.test.util.TestDependencyCollectionContext
-
- All Implemented Interfaces:
DependencyCollectionContext
final class TestDependencyCollectionContext extends java.lang.Object implements DependencyCollectionContext
-
-
Field Summary
Fields Modifier and Type Field Description private Artifact
artifact
private Dependency
dependency
private java.util.List<Dependency>
managedDependencies
private RepositorySystemSession
session
-
Constructor Summary
Constructors Constructor Description TestDependencyCollectionContext(RepositorySystemSession session, Artifact artifact, Dependency dependency, java.util.List<Dependency> managedDependencies)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Artifact
getArtifact()
Gets the artifact whose children are to be processed next during dependency collection.Dependency
getDependency()
Gets the dependency whose children are to be processed next during dependency collection.java.util.List<Dependency>
getManagedDependencies()
Gets the dependency management information that was contributed by the artifact descriptor of the current dependency.RepositorySystemSession
getSession()
Gets the repository system session during which the dependency collection happens.java.lang.String
toString()
-
-
-
Field Detail
-
session
private final RepositorySystemSession session
-
artifact
private final Artifact artifact
-
dependency
private final Dependency dependency
-
managedDependencies
private final java.util.List<Dependency> managedDependencies
-
-
Constructor Detail
-
TestDependencyCollectionContext
TestDependencyCollectionContext(RepositorySystemSession session, Artifact artifact, Dependency dependency, java.util.List<Dependency> managedDependencies)
-
-
Method Detail
-
getSession
public RepositorySystemSession getSession()
Description copied from interface:DependencyCollectionContext
Gets the repository system session during which the dependency collection happens.- Specified by:
getSession
in interfaceDependencyCollectionContext
- Returns:
- The repository system session, never
null
.
-
getArtifact
public Artifact getArtifact()
Description copied from interface:DependencyCollectionContext
Gets the artifact whose children are to be processed next during dependency collection. For all nodes but the root, this is simply shorthand forgetDependency().getArtifact()
. In case of the root node however,DependencyCollectionContext.getDependency()
might benull
while the node still has an artifact which serves as its label and is not to be resolved.- Specified by:
getArtifact
in interfaceDependencyCollectionContext
- Returns:
- The artifact whose children are going to be processed or
null
in case of the root node without dependency and label.
-
getDependency
public Dependency getDependency()
Description copied from interface:DependencyCollectionContext
Gets the dependency whose children are to be processed next during dependency collection.- Specified by:
getDependency
in interfaceDependencyCollectionContext
- Returns:
- The dependency whose children are going to be processed or
null
in case of the root node without dependency.
-
getManagedDependencies
public java.util.List<Dependency> getManagedDependencies()
Description copied from interface:DependencyCollectionContext
Gets the dependency management information that was contributed by the artifact descriptor of the current dependency.- Specified by:
getManagedDependencies
in interfaceDependencyCollectionContext
- Returns:
- The dependency management information, never
null
.
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-