Class ConflictMarker
java.lang.Object
org.eclipse.aether.util.graph.transformer.ConflictMarker
- All Implemented Interfaces:
DependencyGraphTransformer
A dependency graph transformer that identifies conflicting dependencies. When this transformer has executed, the
transformation context holds a
Map<DependencyNode, Object>
where dependency nodes that belong to the same
conflict group will have an equal conflict identifier. This map is stored using the key
TransformationContextKeys.CONFLICT_IDS
.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescription(package private) static class
(package private) static class
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate void
analyze
(DependencyNode node, Map<DependencyNode, Object> nodes, Map<Object, ConflictMarker.ConflictGroup> groups, int[] counter) getKeys
(DependencyNode node) private Map<DependencyNode,
Object> mark
(Collection<DependencyNode> nodes, Map<Object, ConflictMarker.ConflictGroup> groups) private static Object
transformGraph
(DependencyNode node, DependencyGraphTransformationContext context) After the execution of this method, every DependencyNode with an attached dependency is member of one conflict group.
-
Constructor Details
-
ConflictMarker
public ConflictMarker()
-
-
Method Details
-
transformGraph
public DependencyNode transformGraph(DependencyNode node, DependencyGraphTransformationContext context) throws RepositoryException After the execution of this method, every DependencyNode with an attached dependency is member of one conflict group.- Specified by:
transformGraph
in interfaceDependencyGraphTransformer
- Parameters:
node
- The root node of the (possibly cyclic!) graph to transform, must not benull
.context
- The graph transformation context, must not benull
.- Returns:
- The result graph of the transformation, never
null
. - Throws:
RepositoryException
- If the transformation failed.- See Also:
-
analyze
private void analyze(DependencyNode node, Map<DependencyNode, Object> nodes, Map<Object, ConflictMarker.ConflictGroup> groups, int[] counter) -
merge
-
getKeys
-
mark
private Map<DependencyNode,Object> mark(Collection<DependencyNode> nodes, Map<Object, ConflictMarker.ConflictGroup> groups) -
toKey
-