public class DoubleOpenHashSet extends AbstractDoubleSet implements ITrimmable
| Constructor and Description |
|---|
DoubleOpenHashSet()
Default Constructor
|
DoubleOpenHashSet(java.util.Collection<? extends java.lang.Double> collection)
Deprecated.
|
DoubleOpenHashSet(java.util.Collection<? extends java.lang.Double> collection,
float loadFactor)
Deprecated.
|
DoubleOpenHashSet(double[] array)
Helper constructor that allow to create a set from unboxed values
|
DoubleOpenHashSet(double[] array,
float loadFactor)
Helper constructor that allow to create a set from unboxed values
|
DoubleOpenHashSet(double[] array,
int offset,
int length)
Helper constructor that allow to create a set from unboxed values
|
DoubleOpenHashSet(double[] array,
int offset,
int length,
float loadFactor)
Helper constructor that allow to create a set from unboxed values
|
DoubleOpenHashSet(DoubleCollection collection)
A Helper constructor that allows to create a Set with exactly the same values as the provided collection.
|
DoubleOpenHashSet(DoubleCollection collection,
float loadFactor)
A Helper constructor that allows to create a Set with exactly the same values as the provided collection.
|
DoubleOpenHashSet(DoubleIterator iterator)
A Helper constructor that allows to create a set from a iterator of an unknown size
|
DoubleOpenHashSet(DoubleIterator iterator,
float loadFactor)
A Helper constructor that allows to create a set from a iterator of an unknown size
|
DoubleOpenHashSet(int minCapacity)
Constructor that defines the minimum capacity
|
DoubleOpenHashSet(int minCapacity,
float loadFactor)
Constructor that defines the minimum capacity and load factor
|
DoubleOpenHashSet(java.util.Iterator<java.lang.Double> iterator)
A Helper constructor that allows to create a set from a iterator of an unknown size
|
DoubleOpenHashSet(java.util.Iterator<java.lang.Double> iterator,
float loadFactor)
A Helper constructor that allows to create a set from a iterator of an unknown size
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
add(double o)
A Type-Specific add function to reduce (un)boxing
|
boolean |
addAll(java.util.Collection<? extends java.lang.Double> c)
Deprecated.
|
boolean |
addAll(DoubleCollection c)
A Type-Specific addAll function to reduce (un)boxing
|
void |
clear() |
void |
clearAndTrim(int size)
Trims the collection down to the requested size and clears all elements while doing so
|
boolean |
contains(double o)
A Type-Specific implementation of contains.
|
boolean |
contains(java.lang.Object o)
This default implementation delegates to the corresponding type-specific function.
|
DoubleIterator |
iterator()
Returns a Type-Specific Iterator to reduce (un)boxing
|
boolean |
remove(double o)
A Type Specific remove function to reduce boxing/unboxing
|
boolean |
remove(java.lang.Object o)
This default implementation delegates to the corresponding type-specific function.
|
int |
size() |
boolean |
trim(int size)
Trims the original collection down to the size of the current elements or the requested size depending which is bigger
|
equals, hashCodeadd, containsAll, containsAny, containsAny, remDouble, removeAll, retainAll, toDoubleArray, toDoubleArraycontainsAll, isEmpty, removeAll, retainAll, toArray, toArray, toStringclearAndTrim, trimadd, remDouble, spliteratorcontainsAll, isEmpty, removeAll, retainAll, toArray, toArraycontainsAll, containsAny, containsAny, parallelPrimitiveStream, primitiveStream, remIf, removeAll, removeIf, retainAll, toDoubleArray, toDoubleArrayforEach, forEachpublic DoubleOpenHashSet()
public DoubleOpenHashSet(int minCapacity)
minCapacity - the minimum capacity the HashSet is allowed to be.java.lang.IllegalStateException - if the minimum capacity is negativepublic DoubleOpenHashSet(int minCapacity,
float loadFactor)
minCapacity - the minimum capacity the HashSet is allowed to be.loadFactor - the percentage of how full the backing array can be before they resizejava.lang.IllegalStateException - if the minimum capacity is negativejava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1public DoubleOpenHashSet(double[] array)
array - the elements that should be put into the setpublic DoubleOpenHashSet(double[] array,
float loadFactor)
array - the elements that should be put into the setloadFactor - the percentage of how full the backing array can be before they resizejava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1public DoubleOpenHashSet(double[] array,
int offset,
int length)
array - the elements that should be put into the setoffset - the starting index within the array that should be usedlength - the amount of elements used from the arrayjava.lang.IllegalStateException - if offset and length causes to step outside of the arrays rangepublic DoubleOpenHashSet(double[] array,
int offset,
int length,
float loadFactor)
array - the elements that should be put into the setoffset - the starting index within the array that should be usedlength - the amount of elements used from the arrayloadFactor - the percentage of how full the backing array can be before they resizejava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1java.lang.IllegalStateException - if offset and length causes to step outside of the arrays range@Deprecated public DoubleOpenHashSet(java.util.Collection<? extends java.lang.Double> collection)
collection - the set the elements should be added to the Set@Deprecated
public DoubleOpenHashSet(java.util.Collection<? extends java.lang.Double> collection,
float loadFactor)
collection - the set the elements should be added to the SetloadFactor - the percentage of how full the backing array can be before they resizejava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1public DoubleOpenHashSet(DoubleCollection collection)
collection - the set the elements should be added to the Setpublic DoubleOpenHashSet(DoubleCollection collection, float loadFactor)
collection - the set the elements should be added to the SetloadFactor - the percentage of how full the backing array can be before they resizejava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1public DoubleOpenHashSet(java.util.Iterator<java.lang.Double> iterator)
iterator - the elements that should be added to the setpublic DoubleOpenHashSet(java.util.Iterator<java.lang.Double> iterator,
float loadFactor)
iterator - the elements that should be added to the setloadFactor - the percentage of how full the backing array can be before they resizejava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1public DoubleOpenHashSet(DoubleIterator iterator)
iterator - the elements that should be added to the setpublic DoubleOpenHashSet(DoubleIterator iterator, float loadFactor)
iterator - the elements that should be added to the setloadFactor - the percentage of how full the backing array can be before they resizejava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1public boolean add(double o)
DoubleCollectionadd in interface DoubleCollectiono - the element that should be added@Deprecated public boolean addAll(java.util.Collection<? extends java.lang.Double> c)
AbstractDoubleCollectionThis default implementation delegates to the corresponding type-specific function.
addAll in interface java.util.Collection<java.lang.Double>addAll in interface java.util.Set<java.lang.Double>addAll in class AbstractDoubleCollectionpublic boolean addAll(DoubleCollection c)
DoubleCollectionaddAll in interface DoubleCollectionaddAll in class AbstractDoubleCollectionc - the collection of elements that should be addedpublic boolean contains(java.lang.Object o)
AbstractDoubleCollectionThis default implementation delegates to the corresponding type-specific function.
This default implementation delegates to the corresponding type-specific function.
contains in interface java.util.Collection<java.lang.Double>contains in interface java.util.Set<java.lang.Double>contains in interface DoubleCollectioncontains in interface DoubleSetcontains in class AbstractDoubleCollectionpublic boolean remove(java.lang.Object o)
AbstractDoubleCollectionThis default implementation delegates to the corresponding type-specific function.
This default implementation delegates to the corresponding type-specific function.
remove in interface java.util.Collection<java.lang.Double>remove in interface java.util.Set<java.lang.Double>remove in interface DoubleCollectionremove in interface DoubleSetremove in class AbstractDoubleCollectionpublic boolean contains(double o)
AbstractDoubleCollectioncontains in interface DoubleCollectioncontains in class AbstractDoubleCollectiono - the element that should be searched for.public boolean remove(double o)
DoubleSetpublic boolean trim(int size)
ITrimmabletrim in interface ITrimmablesize - the requested trim size.public void clearAndTrim(int size)
ITrimmableclearAndTrim in interface ITrimmablesize - the amount of elements that should be allowedpublic DoubleIterator iterator()
DoubleCollectioniterator in interface java.lang.Iterable<java.lang.Double>iterator in interface java.util.Collection<java.lang.Double>iterator in interface java.util.Set<java.lang.Double>iterator in interface DoubleCollectioniterator in interface DoubleIterableiterator in interface DoubleSetiterator in class AbstractDoubleSetCollection.iterator()public void clear()
clear in interface java.util.Collection<java.lang.Double>clear in interface java.util.Set<java.lang.Double>clear in class java.util.AbstractCollection<java.lang.Double>public int size()
size in interface java.util.Collection<java.lang.Double>size in interface java.util.Set<java.lang.Double>size in class java.util.AbstractCollection<java.lang.Double>