public class FloatOpenCustomHashSet extends AbstractFloatSet implements ITrimmable
| Constructor and Description |
|---|
FloatOpenCustomHashSet(java.util.Collection<? extends java.lang.Float> collection,
float loadFactor,
FloatStrategy strategy)
Deprecated.
|
FloatOpenCustomHashSet(java.util.Collection<? extends java.lang.Float> collection,
FloatStrategy strategy)
Deprecated.
|
FloatOpenCustomHashSet(float[] array,
float loadFactor,
FloatStrategy strategy)
Helper constructor that allow to create a set from unboxed values
|
FloatOpenCustomHashSet(float[] array,
FloatStrategy strategy)
Helper constructor that allow to create a set from unboxed values
|
FloatOpenCustomHashSet(float[] array,
int offset,
int length,
float loadFactor,
FloatStrategy strategy)
Helper constructor that allow to create a set from unboxed values
|
FloatOpenCustomHashSet(float[] array,
int offset,
int length,
FloatStrategy strategy)
Helper constructor that allow to create a set from unboxed values
|
FloatOpenCustomHashSet(FloatCollection collection,
float loadFactor,
FloatStrategy strategy)
A Helper constructor that allows to create a Set with exactly the same values as the provided collection.
|
FloatOpenCustomHashSet(FloatCollection collection,
FloatStrategy strategy)
A Helper constructor that allows to create a Set with exactly the same values as the provided collection.
|
FloatOpenCustomHashSet(FloatIterator iterator,
float loadFactor,
FloatStrategy strategy)
A Helper constructor that allows to create a set from a iterator of an unknown size
|
FloatOpenCustomHashSet(FloatIterator iterator,
FloatStrategy strategy)
A Helper constructor that allows to create a set from a iterator of an unknown size
|
FloatOpenCustomHashSet(FloatStrategy strategy)
Default Contstructor
|
FloatOpenCustomHashSet(int minCapacity,
float loadFactor,
FloatStrategy strategy)
Constructor that defines the minimum capacity and load factor
|
FloatOpenCustomHashSet(int minCapacity,
FloatStrategy strategy)
Constructor that defines the minimum capacity
|
FloatOpenCustomHashSet(java.util.Iterator<java.lang.Float> iterator,
float loadFactor,
FloatStrategy strategy)
A Helper constructor that allows to create a set from a iterator of an unknown size
|
FloatOpenCustomHashSet(java.util.Iterator<java.lang.Float> iterator,
FloatStrategy strategy)
A Helper constructor that allows to create a set from a iterator of an unknown size
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
add(float o)
A Type-Specific add function to reduce (un)boxing
|
boolean |
addAll(java.util.Collection<? extends java.lang.Float> c)
Deprecated.
|
boolean |
addAll(FloatCollection 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(float o)
A Type-Specific implementation of contains.
|
FloatStrategy |
getStrategy()
Helper getter function to get the current strategy
|
FloatIterator |
iterator()
Returns a Type-Specific Iterator to reduce (un)boxing
|
boolean |
remove(float o)
A Type Specific remove function to reduce boxing/unboxing
|
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, contains, containsAll, containsAny, containsAny, remFloat, remove, removeAll, retainAll, toFloatArray, toFloatArraycontainsAll, isEmpty, removeAll, retainAll, toArray, toArray, toStringclearAndTrim, trimadd, contains, remFloat, remove, spliteratorcontainsAll, isEmpty, removeAll, retainAll, toArray, toArraycontainsAll, containsAny, containsAny, parallelPrimitiveStream, primitiveStream, remIf, removeAll, removeIf, retainAll, toFloatArray, toFloatArrayforEach, forEachpublic FloatOpenCustomHashSet(FloatStrategy strategy)
strategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nullpublic FloatOpenCustomHashSet(int minCapacity,
FloatStrategy strategy)
minCapacity - the minimum capacity the HashSet is allowed to be.strategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nulljava.lang.IllegalStateException - if the minimum capacity is negativepublic FloatOpenCustomHashSet(int minCapacity,
float loadFactor,
FloatStrategy strategy)
minCapacity - the minimum capacity the HashSet is allowed to be.loadFactor - the percentage of how full the backing array can be before they resizestrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nulljava.lang.IllegalStateException - if the minimum capacity is negativejava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1public FloatOpenCustomHashSet(float[] array,
FloatStrategy strategy)
array - the elements that should be put into the setstrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nullpublic FloatOpenCustomHashSet(float[] array,
float loadFactor,
FloatStrategy strategy)
array - the elements that should be put into the setloadFactor - the percentage of how full the backing array can be before they resizestrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nulljava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1public FloatOpenCustomHashSet(float[] array,
int offset,
int length,
FloatStrategy strategy)
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 arraystrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nulljava.lang.IllegalStateException - if offset and length causes to step outside of the arrays rangepublic FloatOpenCustomHashSet(float[] array,
int offset,
int length,
float loadFactor,
FloatStrategy strategy)
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 resizestrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nulljava.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 FloatOpenCustomHashSet(java.util.Collection<? extends java.lang.Float> collection,
FloatStrategy strategy)
collection - the set the elements should be added to the Setstrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is null@Deprecated
public FloatOpenCustomHashSet(java.util.Collection<? extends java.lang.Float> collection,
float loadFactor,
FloatStrategy strategy)
collection - the set the elements should be added to the SetloadFactor - the percentage of how full the backing array can be before they resizestrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nulljava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1public FloatOpenCustomHashSet(FloatCollection collection, FloatStrategy strategy)
collection - the set the elements should be added to the Setstrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nullpublic FloatOpenCustomHashSet(FloatCollection collection, float loadFactor, FloatStrategy strategy)
collection - the set the elements should be added to the SetloadFactor - the percentage of how full the backing array can be before they resizestrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nulljava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1public FloatOpenCustomHashSet(java.util.Iterator<java.lang.Float> iterator,
FloatStrategy strategy)
iterator - the elements that should be added to the setstrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nullpublic FloatOpenCustomHashSet(java.util.Iterator<java.lang.Float> iterator,
float loadFactor,
FloatStrategy strategy)
iterator - the elements that should be added to the setloadFactor - the percentage of how full the backing array can be before they resizestrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nulljava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1public FloatOpenCustomHashSet(FloatIterator iterator, FloatStrategy strategy)
iterator - the elements that should be added to the setstrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nullpublic FloatOpenCustomHashSet(FloatIterator iterator, float loadFactor, FloatStrategy strategy)
iterator - the elements that should be added to the setloadFactor - the percentage of how full the backing array can be before they resizestrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nulljava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1public FloatStrategy getStrategy()
public boolean add(float o)
FloatCollectionadd in interface FloatCollectiono - the element that should be added@Deprecated public boolean addAll(java.util.Collection<? extends java.lang.Float> c)
AbstractFloatCollectionThis default implementation delegates to the corresponding type-specific function.
addAll in interface java.util.Collection<java.lang.Float>addAll in interface java.util.Set<java.lang.Float>addAll in class AbstractFloatCollectionpublic boolean addAll(FloatCollection c)
FloatCollectionaddAll in interface FloatCollectionaddAll in class AbstractFloatCollectionc - the collection of elements that should be addedpublic boolean contains(float o)
AbstractFloatCollectioncontains in interface FloatCollectioncontains in class AbstractFloatCollectiono - the element that should be searched for.public boolean remove(float o)
FloatSetpublic 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 FloatIterator iterator()
FloatCollectioniterator in interface java.lang.Iterable<java.lang.Float>iterator in interface java.util.Collection<java.lang.Float>iterator in interface java.util.Set<java.lang.Float>iterator in interface FloatCollectioniterator in interface FloatIterableiterator in interface FloatSetiterator in class AbstractFloatSetCollection.iterator()public void clear()
clear in interface java.util.Collection<java.lang.Float>clear in interface java.util.Set<java.lang.Float>clear in class java.util.AbstractCollection<java.lang.Float>public int size()
size in interface java.util.Collection<java.lang.Float>size in interface java.util.Set<java.lang.Float>size in class java.util.AbstractCollection<java.lang.Float>