Package com.github.tommyettinger.ds
Class EnumLongMap.Entries
- All Implemented Interfaces:
EnhancedCollection<EnumLongMap.Entry>,Iterable<EnumLongMap.Entry>,Collection<EnumLongMap.Entry>,Set<EnumLongMap.Entry>
- Direct Known Subclasses:
EnumLongOrderedMap.OrderedMapEntries
- Enclosing class:
- EnumLongMap
public static class EnumLongMap.Entries
extends AbstractSet<EnumLongMap.Entry>
implements EnhancedCollection<EnumLongMap.Entry>
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionappendInto(EnumLongMap coll) Append the remaining items that this can iterate through into the given EnumLongMap.ObjectLongMap<Enum<?>>appendInto(ObjectLongMap<Enum<?>> coll) Append the remaining items that this can iterate through into the given ObjectLongMap.Append the remaining items that this can iterate through into the given Collection.voidclear()booleanbooleancontainsAll(Collection<?> c) booleaninthashCode()iterator()Returns an iterator over the elements contained in this collection.booleanbooleanremoveAll(Collection<?> c) Removes from this set all of its elements that are contained in the specified collection (optional operation).voidThe iterator is reused by this data structure, and you can reset it back to the start of the iteration order using this.booleanretainAll(Collection<?> c) intsize()Object[]toArray()<T> T[]toArray(T[] a) toList()Returns a newObjectListcontaining the remaining items.toString()Methods inherited from class java.util.AbstractCollection
add, addAll, isEmptyMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArrayMethods inherited from interface com.github.tommyettinger.ds.EnhancedCollection
add, add, add, addAll, addAll, addAll, addAllIterable, addLegible, addLegible, addVarargs, appendTo, appendTo, containsAll, containsAll, containsAll, containsAllIterable, containsAny, containsAny, containsAny, containsAnyIterable, first, removeAll, removeAll, removeAll, removeAllIterable, removeEach, removeEach, removeEach, removeEachIterable, toString, toString, toStringMethods inherited from interface java.util.Set
add, addAll, isEmpty, spliterator
-
Field Details
-
entry
-
iter
-
-
Constructor Details
-
Entries
-
-
Method Details
-
contains
- Specified by:
containsin interfaceCollection<EnumLongMap.Entry>- Specified by:
containsin interfaceSet<EnumLongMap.Entry>- Overrides:
containsin classAbstractCollection<EnumLongMap.Entry>
-
remove
- Specified by:
removein interfaceCollection<EnumLongMap.Entry>- Specified by:
removein interfaceSet<EnumLongMap.Entry>- Overrides:
removein classAbstractCollection<EnumLongMap.Entry>
-
removeAll
Removes from this set all of its elements that are contained in the specified collection (optional operation). If the specified collection is also a set, this operation effectively modifies this set so that its value is the asymmetric set difference of the two sets.- Specified by:
removeAllin interfaceCollection<EnumLongMap.Entry>- Specified by:
removeAllin interfaceSet<EnumLongMap.Entry>- Overrides:
removeAllin classAbstractSet<EnumLongMap.Entry>- Parameters:
c- collection containing elements to be removed from this set- Returns:
trueif this set changed as a result of the call
-
retainAll
- Specified by:
retainAllin interfaceCollection<EnumLongMap.Entry>- Specified by:
retainAllin interfaceSet<EnumLongMap.Entry>- Overrides:
retainAllin classAbstractCollection<EnumLongMap.Entry>- Parameters:
c-- "Implementation Requirements"
- This implementation iterates over this collection, checking each
element returned by the iterator in turn to see if it's contained
in the specified collection. If it's not so contained, it's removed
from this collection with the iterator's
removemethod.
-
containsAll
- Specified by:
containsAllin interfaceCollection<EnumLongMap.Entry>- Specified by:
containsAllin interfaceSet<EnumLongMap.Entry>- Overrides:
containsAllin classAbstractCollection<EnumLongMap.Entry>- Parameters:
c- a Collection of any type- Returns:
- true if all elements in c are contained in this set; false otherwise
- See Also:
-
iterator
Returns an iterator over the elements contained in this collection.- Specified by:
iteratorin interfaceCollection<EnumLongMap.Entry>- Specified by:
iteratorin interfaceIterable<EnumLongMap.Entry>- Specified by:
iteratorin interfaceSet<EnumLongMap.Entry>- Specified by:
iteratorin classAbstractCollection<EnumLongMap.Entry>- Returns:
- an iterator over the elements contained in this collection
-
size
public int size()- Specified by:
sizein interfaceCollection<EnumLongMap.Entry>- Specified by:
sizein interfaceSet<EnumLongMap.Entry>- Specified by:
sizein classAbstractCollection<EnumLongMap.Entry>
-
hashCode
public int hashCode()- Specified by:
hashCodein interfaceCollection<EnumLongMap.Entry>- Specified by:
hashCodein interfaceSet<EnumLongMap.Entry>- Overrides:
hashCodein classAbstractSet<EnumLongMap.Entry>
-
equals
- Specified by:
equalsin interfaceCollection<EnumLongMap.Entry>- Specified by:
equalsin interfaceSet<EnumLongMap.Entry>- Overrides:
equalsin classAbstractSet<EnumLongMap.Entry>
-
toString
- Overrides:
toStringin classAbstractCollection<EnumLongMap.Entry>
-
clear
public void clear()- Specified by:
clearin interfaceCollection<EnumLongMap.Entry>- Specified by:
clearin interfaceSet<EnumLongMap.Entry>- Overrides:
clearin classAbstractCollection<EnumLongMap.Entry>
-
resetIterator
public void resetIterator()The iterator is reused by this data structure, and you can reset it back to the start of the iteration order using this. -
toArray
- Specified by:
toArrayin interfaceCollection<EnumLongMap.Entry>- Specified by:
toArrayin interfaceSet<EnumLongMap.Entry>- Overrides:
toArrayin classAbstractCollection<EnumLongMap.Entry>
-
toArray
public <T> T[] toArray(T[] a) - Specified by:
toArrayin interfaceCollection<EnumLongMap.Entry>- Specified by:
toArrayin interfaceSet<EnumLongMap.Entry>- Overrides:
toArrayin classAbstractCollection<EnumLongMap.Entry>- Parameters:
a-
-
toList
Returns a newObjectListcontaining the remaining items. Does not change the position of this iterator. -
appendInto
Append the remaining items that this can iterate through into the given Collection. Does not change the position of this iterator.- Parameters:
coll- any modifiable Collection; may have items appended into it- Returns:
- the given collection
-
appendInto
Append the remaining items that this can iterate through into the given ObjectLongMap. Does not change the position of this iterator. The ObjectLongMap must have Enum keys.- Parameters:
coll- a modifiable ObjectLongMap; may have items appended into it- Returns:
- the given ObjectLongMap
-
appendInto
Append the remaining items that this can iterate through into the given EnumLongMap. Does not change the position of this iterator.- Parameters:
coll- another EnumLongMap; may have items appended into it- Returns:
- the given EnumLongMap
-