public class IntLinkedOpenCustomHashSet extends IntOpenCustomHashSet implements IntOrderedSet
| Constructor and Description |
|---|
IntLinkedOpenCustomHashSet(java.util.Collection<? extends java.lang.Integer> collection,
float loadFactor,
IntStrategy strategy)
Deprecated.
|
IntLinkedOpenCustomHashSet(java.util.Collection<? extends java.lang.Integer> collection,
IntStrategy strategy)
Deprecated.
|
IntLinkedOpenCustomHashSet(int[] array,
float loadFactor,
IntStrategy strategy)
Helper constructor that allow to create a set from unboxed values
|
IntLinkedOpenCustomHashSet(int[] array,
int offset,
int length,
float loadFactor,
IntStrategy strategy)
Helper constructor that allow to create a set from unboxed values
|
IntLinkedOpenCustomHashSet(int[] array,
int offset,
int length,
IntStrategy strategy)
Helper constructor that allow to create a set from unboxed values
|
IntLinkedOpenCustomHashSet(int[] array,
IntStrategy strategy)
Helper constructor that allow to create a set from unboxed values
|
IntLinkedOpenCustomHashSet(IntCollection collection,
float loadFactor,
IntStrategy strategy)
A Helper constructor that allows to create a Set with exactly the same values as the provided collection.
|
IntLinkedOpenCustomHashSet(IntCollection collection,
IntStrategy strategy)
A Helper constructor that allows to create a Set with exactly the same values as the provided collection.
|
IntLinkedOpenCustomHashSet(int minCapacity,
float loadFactor,
IntStrategy strategy)
Constructor that defines the minimum capacity and load factor
|
IntLinkedOpenCustomHashSet(int minCapacity,
IntStrategy strategy)
Constructor that defines the minimum capacity
|
IntLinkedOpenCustomHashSet(IntIterator iterator,
float loadFactor,
IntStrategy strategy)
A Helper constructor that allows to create a set from a iterator of an unknown size
|
IntLinkedOpenCustomHashSet(IntIterator iterator,
IntStrategy strategy)
A Helper constructor that allows to create a set from a iterator of an unknown size
|
IntLinkedOpenCustomHashSet(IntStrategy strategy)
Default Contstructor
|
IntLinkedOpenCustomHashSet(java.util.Iterator<java.lang.Integer> iterator,
float loadFactor,
IntStrategy strategy)
A Helper constructor that allows to create a set from a iterator of an unknown size
|
IntLinkedOpenCustomHashSet(java.util.Iterator<java.lang.Integer> iterator,
IntStrategy strategy)
A Helper constructor that allows to create a set from a iterator of an unknown size
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
addAndMoveToFirst(int o)
A customized add method that allows you to insert into the first index.
|
boolean |
addAndMoveToLast(int o)
A customized add method that allows you to insert into the last index.
|
void |
clear() |
void |
clearAndTrim(int size)
Trims the collection down to the requested size and clears all elements while doing so
|
IntLinkedOpenCustomHashSet |
copy()
A Function that does a shallow clone of the Collection itself.
|
int |
count(Int2BooleanFunction filter)
Helper function to reduce stream usage that allows to count the valid elements.
|
int |
findFirst(Int2BooleanFunction filter)
Helper function to reduce stream usage that allows to filter for the first match.
|
int |
firstInt()
A method to get the first element in the set
|
<E> void |
forEach(E input,
ObjectIntConsumer<E> action)
Helper function to reduce Lambda usage and allow for more method references, since these are faster/cleaner.
|
void |
forEach(IntConsumer action)
A Type Specific foreach function that reduces (un)boxing
|
IntListIterator |
iterator()
Returns a Type-Specific Iterator to reduce (un)boxing
|
IntBidirectionalIterator |
iterator(int fromElement)
A type Specific Iterator starting from a given key
|
int |
lastInt()
A method to get the last element in the set
|
boolean |
matchesAll(Int2BooleanFunction filter)
Helper function to reduce stream usage that allows to filter for all matches.
|
boolean |
matchesAny(Int2BooleanFunction filter)
Helper function to reduce stream usage that allows to filter for any matches.
|
boolean |
matchesNone(Int2BooleanFunction filter)
Helper function to reduce stream usage that allows to filter for no matches.
|
boolean |
moveToFirst(int o)
A specific move method to move a given key to the first index.
|
boolean |
moveToLast(int o)
A specific move method to move a given key to the last index.
|
int |
pollFirstInt()
A method to get and remove the first element in the set
|
int |
pollLastInt()
A method to get and remove the last element in the set
|
int |
reduce(int identity,
IntIntUnaryOperator operator)
Performs a reduction on the
elements of this Iterable
|
int |
reduce(IntIntUnaryOperator operator)
Performs a reduction on the
elements of this Iterable
|
add, addAll, addAll, contains, getStrategy, remove, size, trimequals, hashCodeadd, contains, containsAll, containsAll, containsAny, containsAny, remInt, remove, removeAll, removeAll, retainAll, retainAll, toIntArray, toIntArrayisEmpty, removeAll, retainAll, toArray, toArray, toStringspliterator, synchronize, synchronize, unmodifiableadd, contains, remInt, remove, removeaddAll, containsAll, equals, hashCode, isEmpty, removeAll, retainAll, size, toArray, toArrayadd, addAll, addAll, addAll, addAll, contains, containsAll, containsAny, containsAny, parallelPrimitiveStream, pour, primitiveStream, remIf, removeAll, removeAll, removeIf, retainAll, retainAll, toIntArray, toIntArrayarrayflatMap, asAsync, distinct, filter, flatMap, forEach, limit, map, peek, pourAsList, pourAsSet, sortedclearAndTrim, trimpublic IntLinkedOpenCustomHashSet(IntStrategy strategy)
strategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nullpublic IntLinkedOpenCustomHashSet(int minCapacity,
IntStrategy 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 IntLinkedOpenCustomHashSet(int minCapacity,
float loadFactor,
IntStrategy 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 IntLinkedOpenCustomHashSet(int[] array,
IntStrategy strategy)
array - the elements that should be put into the setstrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nullpublic IntLinkedOpenCustomHashSet(int[] array,
float loadFactor,
IntStrategy 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 IntLinkedOpenCustomHashSet(int[] array,
int offset,
int length,
IntStrategy 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 IntLinkedOpenCustomHashSet(int[] array,
int offset,
int length,
float loadFactor,
IntStrategy 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 IntLinkedOpenCustomHashSet(java.util.Collection<? extends java.lang.Integer> collection,
IntStrategy 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 IntLinkedOpenCustomHashSet(java.util.Collection<? extends java.lang.Integer> collection,
float loadFactor,
IntStrategy 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 IntLinkedOpenCustomHashSet(IntCollection collection, IntStrategy 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 IntLinkedOpenCustomHashSet(IntCollection collection, float loadFactor, IntStrategy 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 IntLinkedOpenCustomHashSet(java.util.Iterator<java.lang.Integer> iterator,
IntStrategy strategy)
iterator - the elements that should be added to the setstrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nullpublic IntLinkedOpenCustomHashSet(java.util.Iterator<java.lang.Integer> iterator,
float loadFactor,
IntStrategy 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 IntLinkedOpenCustomHashSet(IntIterator iterator, IntStrategy strategy)
iterator - the elements that should be added to the setstrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nullpublic IntLinkedOpenCustomHashSet(IntIterator iterator, float loadFactor, IntStrategy 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 boolean addAndMoveToFirst(int o)
IntOrderedSetaddAndMoveToFirst in interface IntOrderedSeto - the element that should be insertedSet.add(Object)public boolean addAndMoveToLast(int o)
IntOrderedSetaddAndMoveToLast in interface IntOrderedSeto - the element that should be insertedSet.add(Object)public boolean moveToFirst(int o)
IntOrderedSetmoveToFirst in interface IntOrderedSeto - that should be moved to the first indexpublic boolean moveToLast(int o)
IntOrderedSetmoveToLast in interface IntOrderedSeto - that should be moved to the first lastpublic int firstInt()
IntOrderedSetfirstInt in interface IntOrderedSetpublic int pollFirstInt()
IntOrderedSetpollFirstInt in interface IntOrderedSetpublic int lastInt()
IntOrderedSetlastInt in interface IntOrderedSetpublic int pollLastInt()
IntOrderedSetpollLastInt in interface IntOrderedSetpublic void clear()
clear in interface java.util.Collection<java.lang.Integer>clear in interface java.util.Set<java.lang.Integer>clear in class IntOpenCustomHashSetpublic void clearAndTrim(int size)
ITrimmableclearAndTrim in interface ITrimmableclearAndTrim in class IntOpenCustomHashSetsize - the amount of elements that should be allowedpublic void forEach(IntConsumer action)
IntIterableforEach in interface IntIterableforEach in class IntOpenCustomHashSetaction - The action to be performed for each elementIterable.forEach(Consumer)public <E> void forEach(E input,
ObjectIntConsumer<E> action)
IntIterableforEach in interface IntIterableforEach in class IntOpenCustomHashSetE - the generic type of the Objectinput - the object that should be includedaction - The action to be performed for each elementpublic boolean matchesAny(Int2BooleanFunction filter)
IntIterablematchesAny in interface IntIterablematchesAny in class IntOpenCustomHashSetfilter - that should be appliedpublic boolean matchesNone(Int2BooleanFunction filter)
IntIterablematchesNone in interface IntIterablematchesNone in class IntOpenCustomHashSetfilter - that should be appliedpublic boolean matchesAll(Int2BooleanFunction filter)
IntIterablematchesAll in interface IntIterablematchesAll in class IntOpenCustomHashSetfilter - that should be appliedpublic int reduce(int identity,
IntIntUnaryOperator operator)
IntIterablereduce in interface IntIterablereduce in class IntOpenCustomHashSetidentity - the start valueoperator - the operation that should be appliedpublic int reduce(IntIntUnaryOperator operator)
IntIterablereduce in interface IntIterablereduce in class IntOpenCustomHashSetoperator - the operation that should be appliedpublic int findFirst(Int2BooleanFunction filter)
IntIterablefindFirst in interface IntIterablefindFirst in class IntOpenCustomHashSetfilter - that should be appliedpublic int count(Int2BooleanFunction filter)
IntIterablecount in interface IntIterablecount in class IntOpenCustomHashSetfilter - that should be appliedpublic IntListIterator iterator()
IntCollectioniterator in interface java.lang.Iterable<java.lang.Integer>iterator in interface java.util.Collection<java.lang.Integer>iterator in interface java.util.Set<java.lang.Integer>iterator in interface IntCollectioniterator in interface IntIterableiterator in interface IntOrderedSetiterator in interface IntSetiterator in class IntOpenCustomHashSetCollection.iterator()public IntBidirectionalIterator iterator(int fromElement)
IntOrderedSetiterator in interface IntOrderedSetfromElement - the element the iterator should start frompublic IntLinkedOpenCustomHashSet copy()
IntCollectioncopy in interface IntCollectioncopy in interface IntOrderedSetcopy in interface IntSetcopy in class IntOpenCustomHashSet