public final class LongCollections extends Object
The methods of this class all throw a NullPoLongerException if the provided collection is null.
Modifier and Type | Field and Description |
---|---|
static LongIterator |
EMPTY_LONG_ITERATOR
An unmodifiable, empty LongIterator
|
static LongList |
EMPTY_LONG_LIST
An unmodifiable, empty LongList
|
static LongListIterator |
EMPTY_LONG_LIST_ITERATOR
An unmodifiable, empty LongListIterator
|
Constructor and Description |
---|
LongCollections() |
Modifier and Type | Method and Description |
---|---|
static LongIterator |
getEmptyLongIterator()
Returns an unmodifiable, empty LongIterator
|
static LongList |
getEmptyLongList()
Returns an unmodifiable, empty LongList.
|
static LongListIterator |
getEmptyLongListIterator()
Returns an unmodifiable, empty LongListIterator
|
static LongIterator |
singletonLongIterator(long value)
Returns an unmodifiable LongIterator containing only the specified element.
|
static LongList |
singletonLongList(long value)
Returns an unmodifiable LongList containing only the specified element.
|
static LongListIterator |
singletonLongListIterator(long value)
Returns an unmodifiable LongListIterator containing only the specified element.
|
static LongIterator |
unmodifiableLongIterator(LongIterator iter)
Returns an unmodifiable version of the given non-null LongIterator.
|
static LongList |
unmodifiableLongList(LongList list)
Returns an unmodifiable version of the given non-null LongList.
|
static LongListIterator |
unmodifiableLongListIterator(LongListIterator iter)
Returns an unmodifiable version of the given non-null LongListIterator.
|
public static final LongList EMPTY_LONG_LIST
getEmptyLongList()
public static final LongIterator EMPTY_LONG_ITERATOR
getEmptyLongIterator()
public static final LongListIterator EMPTY_LONG_LIST_ITERATOR
getEmptyLongListIterator()
public LongCollections()
public static LongList singletonLongList(long value)
value
- the single valuepublic static LongIterator singletonLongIterator(long value)
value
- the single valuepublic static LongListIterator singletonLongListIterator(long value)
value
- the single valuepublic static LongList unmodifiableLongList(LongList list) throws NullPointerException
list
- the non-null LongList to wrap in an unmodifiable decoratorNullPointerException
- if the given LongList is nullUnmodifiableLongList.wrap(org.apache.commons.collections.primitives.LongList)
public static LongIterator unmodifiableLongIterator(LongIterator iter)
iter
- the non-null LongIterator to wrap in an unmodifiable decoratorNullPointerException
- if the given LongIterator is nullUnmodifiableLongIterator.wrap(org.apache.commons.collections.primitives.LongIterator)
public static LongListIterator unmodifiableLongListIterator(LongListIterator iter)
iter
- the non-null LongListIterator to wrap in an unmodifiable decoratorNullPointerException
- if the given LongListIterator is nullUnmodifiableLongListIterator.wrap(org.apache.commons.collections.primitives.LongListIterator)
public static LongList getEmptyLongList()
EMPTY_LONG_LIST
public static LongIterator getEmptyLongIterator()
EMPTY_LONG_ITERATOR
public static LongListIterator getEmptyLongListIterator()
EMPTY_LONG_LIST_ITERATOR
Copyright © 2002-2013 The Apache Software Foundation. All Rights Reserved.