Class IntIntOrderedMap.KeySet
- All Implemented Interfaces:
Serializable,Iterable<Integer>,Collection<Integer>,Set<Integer>,SortedSet<Integer>
- Enclosing class:
- IntIntOrderedMap
public final class IntIntOrderedMap.KeySet extends Object implements SortedSet<Integer>, Serializable
- See Also:
- Serialized Form
-
Constructor Summary
Constructors Constructor Description KeySet() -
Method Summary
Modifier and Type Method Description booleanadd(Integer o)Always throws an UnsupportedOperationExceptionbooleanaddAll(Collection<? extends Integer> c)Adds all elements of the given collection to this collection.voidclear()Comparator<Integer>comparator()booleancontains(Object o)Delegates to the corresponding type-specific method.booleancontainsAll(Collection<?> c)Checks whether this collection contains all elements from the given type-specific collection.booleanequals(Object o)Integerfirst()SortedSet<Integer>headSet(Integer to)booleanisEmpty()IntIntOrderedMap.KeyIteratoriterator()Integerlast()booleanremove(Object ok)Always throws an UnsupportedOperationExceptionbooleanremoveAll(Collection<?> c)Remove from this collection all elements in the given type-specific collection.booleanretainAll(Collection<?> c)Retains in this collection only elements from the given type-specific collection.intsize()SortedSet<Integer>subSet(Integer from, Integer to)SortedSet<Integer>tailSet(Integer from)Object[]toArray()<T> T[]toArray(T[] a)int[]toIntArray()int[]toIntArray(int[] a)StringtoString()intunwrap(IntIntOrderedMap.KeyIterator i, int[] array)Unwraps an iterator into an array.intunwrap(IntIntOrderedMap.KeyIterator i, int[] array, int offset, int max)Unwraps an iterator into an array starting at a given offset for a given number of elements.intunwrap(IntIntOrderedMap.KeyIterator i, Object[] array)Unwraps an iterator into an array.intunwrap(IntIntOrderedMap.KeyIterator i, Object[] array, int offset, int max)Unwraps an iterator into an array starting at a given offset for a given number of elements.
-
Constructor Details
-
Method Details
-
iterator
-
size
-
clear
-
first
-
last
-
comparator
- Specified by:
comparatorin interfaceSortedSet<Integer>
-
tailSet
-
headSet
-
subSet
-
toArray
-
remove
Always throws an UnsupportedOperationException -
add
Always throws an UnsupportedOperationException -
contains
Delegates to the corresponding type-specific method. -
containsAll
Checks whether this collection contains all elements from the given type-specific collection.- Specified by:
containsAllin interfaceCollection<Integer>- Specified by:
containsAllin interfaceSet<Integer>- Parameters:
c- a type-specific collection.- Returns:
trueif this collection contains all elements of the argument.
-
retainAll
Retains in this collection only elements from the given type-specific collection. -
removeAll
Remove from this collection all elements in the given type-specific collection. -
toArray
-
addAll
Adds all elements of the given collection to this collection. -
equals
-
unwrap
Unwraps an iterator into an array starting at a given offset for a given number of elements.This method iterates over the given type-specific iterator and stores the elements returned, up to a maximum of
length, in the given array starting atoffset. The number of actually unwrapped elements is returned (it may be less thanmaxif the iterator emits less thanmaxelements).- Parameters:
i- a type-specific iterator.array- an array to contain the output of the iterator.offset- the first element of the array to be returned.max- the maximum number of elements to unwrap.- Returns:
- the number of elements unwrapped.
-
unwrap
Unwraps an iterator into an array.This method iterates over the given type-specific iterator and stores the elements returned in the given array. The iteration will stop when the iterator has no more elements or when the end of the array has been reached.
- Parameters:
i- a type-specific iterator.array- an array to contain the output of the iterator.- Returns:
- the number of elements unwrapped.
-
toIntArray
-
toIntArray
-
unwrap
Unwraps an iterator into an array starting at a given offset for a given number of elements.This method iterates over the given type-specific iterator and stores the elements returned, up to a maximum of
length, in the given array starting atoffset. The number of actually unwrapped elements is returned (it may be less thanmaxif the iterator emits less thanmaxelements).- Parameters:
i- a type-specific iterator.array- an array to contain the output of the iterator.offset- the first element of the array to be returned.max- the maximum number of elements to unwrap.- Returns:
- the number of elements unwrapped.
-
unwrap
Unwraps an iterator into an array.This method iterates over the given type-specific iterator and stores the elements returned in the given array. The iteration will stop when the iterator has no more elements or when the end of the array has been reached.
- Parameters:
i- a type-specific iterator.array- an array to contain the output of the iterator.- Returns:
- the number of elements unwrapped.
-
isEmpty
-
toString
-