Class AndDependencySelector

java.lang.Object
org.eclipse.aether.util.graph.selector.AndDependencySelector
All Implemented Interfaces:
org.eclipse.aether.collection.DependencySelector

public final class AndDependencySelector extends Object implements org.eclipse.aether.collection.DependencySelector
A dependency selector that combines zero or more other selectors using a logical AND. The resulting selector selects a given dependency if and only if all constituent selectors do so.
  • Constructor Summary

    Constructors
    Constructor
    Description
    AndDependencySelector(Collection<? extends org.eclipse.aether.collection.DependencySelector> selectors)
    Creates a new selector from the specified selectors.
    AndDependencySelector(org.eclipse.aether.collection.DependencySelector... selectors)
    Creates a new selector from the specified selectors.
  • Method Summary

    Modifier and Type
    Method
    Description
    org.eclipse.aether.collection.DependencySelector
    deriveChildSelector(org.eclipse.aether.collection.DependencyCollectionContext context)
     
    boolean
     
    int
     
    static org.eclipse.aether.collection.DependencySelector
    newInstance(org.eclipse.aether.collection.DependencySelector selector1, org.eclipse.aether.collection.DependencySelector selector2)
    Creates a new selector from the specified selectors.
    boolean
    selectDependency(org.eclipse.aether.graph.Dependency dependency)
     
     

    Methods inherited from class java.lang.Object

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

    • AndDependencySelector

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

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

    • newInstance

      public static org.eclipse.aether.collection.DependencySelector newInstance(org.eclipse.aether.collection.DependencySelector selector1, org.eclipse.aether.collection.DependencySelector selector2)
      Creates a new selector from the specified selectors.
      Parameters:
      selector1 - The first selector to combine, may be null.
      selector2 - The second selector to combine, may be null.
      Returns:
      The combined selector or null if both selectors were null.
    • selectDependency

      public boolean selectDependency(org.eclipse.aether.graph.Dependency dependency)
      Specified by:
      selectDependency in interface org.eclipse.aether.collection.DependencySelector
    • deriveChildSelector

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

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

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object