Class DefaultDependencyCycle
java.lang.Object
org.eclipse.aether.internal.impl.collect.DefaultDependencyCycle
- All Implemented Interfaces:
org.eclipse.aether.graph.DependencyCycle
public final class DefaultDependencyCycle
extends Object
implements org.eclipse.aether.graph.DependencyCycle
Default implementation of
DependencyCycle
.
Internal helper class for collector implementations.-
Constructor Summary
ConstructorDescriptionDefaultDependencyCycle
(List<org.eclipse.aether.graph.DependencyNode> nodes, int cycleEntry, org.eclipse.aether.graph.Dependency dependency) -
Method Summary
Modifier and TypeMethodDescriptionstatic int
find
(List<org.eclipse.aether.graph.DependencyNode> nodes, org.eclipse.aether.artifact.Artifact artifact) Searches for a node associated with the given artifact.List
<org.eclipse.aether.graph.Dependency> List
<org.eclipse.aether.graph.Dependency> toString()
-
Constructor Details
-
DefaultDependencyCycle
public DefaultDependencyCycle(List<org.eclipse.aether.graph.DependencyNode> nodes, int cycleEntry, org.eclipse.aether.graph.Dependency dependency)
-
-
Method Details
-
getPrecedingDependencies
- Specified by:
getPrecedingDependencies
in interfaceorg.eclipse.aether.graph.DependencyCycle
-
getCyclicDependencies
- Specified by:
getCyclicDependencies
in interfaceorg.eclipse.aether.graph.DependencyCycle
-
find
public static int find(List<org.eclipse.aether.graph.DependencyNode> nodes, org.eclipse.aether.artifact.Artifact artifact) Searches for a node associated with the given artifact. A version of the artifact is not considered during the search.- Parameters:
nodes
- a list representing single path in the dependency graph. First element is the root.artifact
- to find among the parent nodes.- Returns:
- the index of the node furthest from the root and associated with the given artifact, or -1 if there is no such node.
-
toString
-