public final class DefaultDependencyCycle extends java.lang.Object implements DependencyCycle
DependencyCycle
.
Internal helper class for collector implementations.Modifier and Type | Field and Description |
---|---|
private int |
cycleEntry |
private java.util.List<Dependency> |
dependencies |
Constructor and Description |
---|
DefaultDependencyCycle(java.util.List<DependencyNode> nodes,
int cycleEntry,
Dependency dependency) |
Modifier and Type | Method and Description |
---|---|
static int |
find(java.util.List<DependencyNode> nodes,
Artifact artifact)
Searches for a node associated with the given artifact.
|
java.util.List<Dependency> |
getCyclicDependencies()
Gets the dependencies that actually form the cycle.
|
java.util.List<Dependency> |
getPrecedingDependencies()
Gets the dependencies that lead to the first dependency on the cycle, starting from the root of the dependency
graph.
|
java.lang.String |
toString() |
private final java.util.List<Dependency> dependencies
private final int cycleEntry
public DefaultDependencyCycle(java.util.List<DependencyNode> nodes, int cycleEntry, Dependency dependency)
public java.util.List<Dependency> getPrecedingDependencies()
DependencyCycle
getPrecedingDependencies
in interface DependencyCycle
null
.public java.util.List<Dependency> getCyclicDependencies()
DependencyCycle
getCyclicDependencies
in interface DependencyCycle
null
.public static int find(java.util.List<DependencyNode> nodes, Artifact artifact)
nodes
- a list representing single path in the dependency graph. First element is the root.artifact
- to find among the parent nodes.public java.lang.String toString()
toString
in class java.lang.Object