Class AndDependencyTraverser

java.lang.Object
org.eclipse.aether.util.graph.traverser.AndDependencyTraverser
All Implemented Interfaces:
org.eclipse.aether.collection.DependencyTraverser

public final class AndDependencyTraverser extends Object implements org.eclipse.aether.collection.DependencyTraverser
A dependency traverser that combines zero or more other traversers using a logical AND. The resulting traverser enables processing of child dependencies if and only if all constituent traversers request traversal.
  • Constructor Summary

    Constructors
    Constructor
    Description
    AndDependencyTraverser(Collection<? extends org.eclipse.aether.collection.DependencyTraverser> traversers)
    Creates a new traverser from the specified traversers.
    AndDependencyTraverser(org.eclipse.aether.collection.DependencyTraverser... traversers)
    Creates a new traverser from the specified traversers.
  • Method Summary

    Modifier and Type
    Method
    Description
    org.eclipse.aether.collection.DependencyTraverser
    deriveChildTraverser(org.eclipse.aether.collection.DependencyCollectionContext context)
     
    boolean
     
    int
     
    static org.eclipse.aether.collection.DependencyTraverser
    newInstance(org.eclipse.aether.collection.DependencyTraverser traverser1, org.eclipse.aether.collection.DependencyTraverser traverser2)
    Creates a new traverser from the specified traversers.
    boolean
    traverseDependency(org.eclipse.aether.graph.Dependency dependency)
     

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • AndDependencyTraverser

      public AndDependencyTraverser(org.eclipse.aether.collection.DependencyTraverser... traversers)
      Creates a new traverser from the specified traversers. Prefer newInstance(DependencyTraverser, DependencyTraverser) if any of the input traversers might be null.
      Parameters:
      traversers - The traversers to combine, may be null but must not contain null elements.
    • AndDependencyTraverser

      public AndDependencyTraverser(Collection<? extends org.eclipse.aether.collection.DependencyTraverser> traversers)
      Creates a new traverser from the specified traversers.
      Parameters:
      traversers - The traversers to combine, may be null but must not contain null elements.
  • Method Details

    • newInstance

      public static org.eclipse.aether.collection.DependencyTraverser newInstance(org.eclipse.aether.collection.DependencyTraverser traverser1, org.eclipse.aether.collection.DependencyTraverser traverser2)
      Creates a new traverser from the specified traversers.
      Parameters:
      traverser1 - The first traverser to combine, may be null.
      traverser2 - The second traverser to combine, may be null.
      Returns:
      The combined traverser or null if both traversers were null.
    • traverseDependency

      public boolean traverseDependency(org.eclipse.aether.graph.Dependency dependency)
      Specified by:
      traverseDependency in interface org.eclipse.aether.collection.DependencyTraverser
    • deriveChildTraverser

      public org.eclipse.aether.collection.DependencyTraverser deriveChildTraverser(org.eclipse.aether.collection.DependencyCollectionContext context)
      Specified by:
      deriveChildTraverser in interface org.eclipse.aether.collection.DependencyTraverser
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object