Package org.opennms.core.collections
Class LazyList<E>
- java.lang.Object
-
- org.opennms.core.collections.LazyList<E>
-
- All Implemented Interfaces:
Iterable<E>
,Collection<E>
,List<E>
public class LazyList<E> extends Object implements List<E>
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
LazyList.Loader<E>
-
Constructor Summary
Constructors Constructor Description LazyList(LazyList.Loader<E> loader)
Constructor for LazyList.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
add(int index, E element)
addboolean
add(E o)
addboolean
addAll(int index, Collection<? extends E> c)
boolean
addAll(Collection<? extends E> arg0)
void
clear()
clearboolean
contains(Object o)
boolean
containsAll(Collection<?> arg0)
E
get(int arg0)
int
indexOf(Object o)
boolean
isEmpty()
isEmptyboolean
isLoaded()
isLoadedIterator<E>
iterator()
iteratorint
lastIndexOf(Object o)
ListIterator<E>
listIterator()
listIteratorListIterator<E>
listIterator(int index)
E
remove(int index)
removeboolean
remove(Object o)
boolean
removeAll(Collection<?> arg0)
boolean
retainAll(Collection<?> c)
E
set(int index, E element)
setint
size()
sizeList<E>
subList(int fromIndex, int toIndex)
Object[]
toArray()
toArray<T> T[]
toArray(T[] arg0)
toArrayString
toString()
toString-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArray
-
Methods inherited from interface java.util.List
equals, hashCode, replaceAll, sort, spliterator
-
-
-
-
Constructor Detail
-
LazyList
public LazyList(LazyList.Loader<E> loader)
Constructor for LazyList.
- Parameters:
loader
- aLazyList.Loader
object.
-
-
Method Detail
-
size
public int size()
size
-
removeAll
public boolean removeAll(Collection<?> arg0)
-
addAll
public boolean addAll(Collection<? extends E> arg0)
-
clear
public void clear()
clear
-
contains
public boolean contains(Object o)
-
containsAll
public boolean containsAll(Collection<?> arg0)
- Specified by:
containsAll
in interfaceCollection<E>
- Specified by:
containsAll
in interfaceList<E>
-
isEmpty
public boolean isEmpty()
isEmpty
-
remove
public boolean remove(Object o)
-
toArray
public Object[] toArray()
toArray
-
toArray
public <T> T[] toArray(T[] arg0)
toArray
-
toString
public String toString()
toString
-
isLoaded
public boolean isLoaded()
isLoaded
- Returns:
- a boolean.
-
add
public boolean add(E o)
add
-
add
public void add(int index, E element)
add
-
addAll
public boolean addAll(int index, Collection<? extends E> c)
-
lastIndexOf
public int lastIndexOf(Object o)
- Specified by:
lastIndexOf
in interfaceList<E>
-
listIterator
public ListIterator<E> listIterator()
listIterator
- Specified by:
listIterator
in interfaceList<E>
- Returns:
- a
ListIterator
object.
-
listIterator
public ListIterator<E> listIterator(int index)
- Specified by:
listIterator
in interfaceList<E>
-
remove
public E remove(int index)
remove
-
retainAll
public boolean retainAll(Collection<?> c)
-
-