Klasse DoubleLinkedOpenCustomHashSet

Alle implementierten Schnittstellen:
Iterable<Double>, Collection<Double>, Set<Double>, DoubleCollection, DoubleIterable, DoubleOrderedSet, DoubleSet, ISizeProvider, ITrimmable

public class DoubleLinkedOpenCustomHashSet extends DoubleOpenCustomHashSet implements DoubleOrderedSet
A Type Specific LinkedHashSet that allows for custom HashControl. That uses arrays to create links between nodes. For cases where Objects/primitive do not allow hashcoding this can be really useful and provide a lot of control. This implementation of SortedSet does not support SubSet of any kind. It implements the interface due to sortability and first/last access
  • Konstruktordetails

    • DoubleLinkedOpenCustomHashSet

      public DoubleLinkedOpenCustomHashSet(DoubleStrategy strategy)
      Default Contstructor
      Parameter:
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
    • DoubleLinkedOpenCustomHashSet

      public DoubleLinkedOpenCustomHashSet(int minCapacity, DoubleStrategy strategy)
      Constructor that defines the minimum capacity
      Parameter:
      minCapacity - the minimum capacity the HashSet is allowed to be.
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
      IllegalStateException - if the minimum capacity is negative
    • DoubleLinkedOpenCustomHashSet

      public DoubleLinkedOpenCustomHashSet(int minCapacity, float loadFactor, DoubleStrategy strategy)
      Constructor that defines the minimum capacity and load factor
      Parameter:
      minCapacity - the minimum capacity the HashSet is allowed to be.
      loadFactor - the percentage of how full the backing array can be before they resize
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
      IllegalStateException - if the minimum capacity is negative
      IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1
    • DoubleLinkedOpenCustomHashSet

      public DoubleLinkedOpenCustomHashSet(double[] array, DoubleStrategy strategy)
      Helper constructor that allow to create a set from unboxed values
      Parameter:
      array - the elements that should be put into the set
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
    • DoubleLinkedOpenCustomHashSet

      public DoubleLinkedOpenCustomHashSet(double[] array, float loadFactor, DoubleStrategy strategy)
      Helper constructor that allow to create a set from unboxed values
      Parameter:
      array - the elements that should be put into the set
      loadFactor - the percentage of how full the backing array can be before they resize
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
      IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1
    • DoubleLinkedOpenCustomHashSet

      public DoubleLinkedOpenCustomHashSet(double[] array, int offset, int length, DoubleStrategy strategy)
      Helper constructor that allow to create a set from unboxed values
      Parameter:
      array - the elements that should be put into the set
      offset - the starting index within the array that should be used
      length - the amount of elements used from the array
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
      IllegalStateException - if offset and length causes to step outside of the arrays range
    • DoubleLinkedOpenCustomHashSet

      public DoubleLinkedOpenCustomHashSet(double[] array, int offset, int length, float loadFactor, DoubleStrategy strategy)
      Helper constructor that allow to create a set from unboxed values
      Parameter:
      array - the elements that should be put into the set
      offset - the starting index within the array that should be used
      length - the amount of elements used from the array
      loadFactor - the percentage of how full the backing array can be before they resize
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
      IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1
      IllegalStateException - if offset and length causes to step outside of the arrays range
    • DoubleLinkedOpenCustomHashSet

      @Deprecated public DoubleLinkedOpenCustomHashSet(Collection<? extends Double> collection, DoubleStrategy strategy)
      Veraltet.
      A Helper constructor that allows to create a Set with exactly the same values as the provided collection.
      Parameter:
      collection - the set the elements should be added to the Set
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
    • DoubleLinkedOpenCustomHashSet

      @Deprecated public DoubleLinkedOpenCustomHashSet(Collection<? extends Double> collection, float loadFactor, DoubleStrategy strategy)
      Veraltet.
      A Helper constructor that allows to create a Set with exactly the same values as the provided collection.
      Parameter:
      collection - the set the elements should be added to the Set
      loadFactor - the percentage of how full the backing array can be before they resize
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
      IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1
    • DoubleLinkedOpenCustomHashSet

      public DoubleLinkedOpenCustomHashSet(DoubleCollection collection, DoubleStrategy strategy)
      A Helper constructor that allows to create a Set with exactly the same values as the provided collection.
      Parameter:
      collection - the set the elements should be added to the Set
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
    • DoubleLinkedOpenCustomHashSet

      public DoubleLinkedOpenCustomHashSet(DoubleCollection collection, float loadFactor, DoubleStrategy strategy)
      A Helper constructor that allows to create a Set with exactly the same values as the provided collection.
      Parameter:
      collection - the set the elements should be added to the Set
      loadFactor - the percentage of how full the backing array can be before they resize
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
      IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1
    • DoubleLinkedOpenCustomHashSet

      public DoubleLinkedOpenCustomHashSet(Iterator<Double> iterator, DoubleStrategy strategy)
      A Helper constructor that allows to create a set from a iterator of an unknown size
      Parameter:
      iterator - the elements that should be added to the set
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
    • DoubleLinkedOpenCustomHashSet

      public DoubleLinkedOpenCustomHashSet(Iterator<Double> iterator, float loadFactor, DoubleStrategy strategy)
      A Helper constructor that allows to create a set from a iterator of an unknown size
      Parameter:
      iterator - the elements that should be added to the set
      loadFactor - the percentage of how full the backing array can be before they resize
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
      IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1
    • DoubleLinkedOpenCustomHashSet

      public DoubleLinkedOpenCustomHashSet(DoubleIterator iterator, DoubleStrategy strategy)
      A Helper constructor that allows to create a set from a iterator of an unknown size
      Parameter:
      iterator - the elements that should be added to the set
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
    • DoubleLinkedOpenCustomHashSet

      public DoubleLinkedOpenCustomHashSet(DoubleIterator iterator, float loadFactor, DoubleStrategy strategy)
      A Helper constructor that allows to create a set from a iterator of an unknown size
      Parameter:
      iterator - the elements that should be added to the set
      loadFactor - the percentage of how full the backing array can be before they resize
      strategy - the strategy that allows hash control.
      Löst aus:
      NullPointerException - if Strategy is null
      IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1
  • Methodendetails