Class CacheableList<E>
java.lang.Object
java.util.AbstractCollection<E>
java.util.AbstractList<E>
java.util.ArrayList<E>
org.deltava.util.cache.CacheableList<E>
- Type Parameters:
E
- the cacheable object type
- All Implemented Interfaces:
Serializable
,Cloneable
,Iterable<E>
,Collection<E>
,List<E>
,RandomAccess
,SequencedCollection<E>
,Cacheable
,CacheableCollection<E>
A utility class to create a cacheable List.
- Since:
- 1.1
- Version:
- 11.2
- Author:
- Luke
- See Also:
-
Field Summary
Fields inherited from class java.util.AbstractList
modCount
-
Constructor Summary
ConstructorsConstructorDescriptionCacheableList
(Object key) Initializes the cachable List.CacheableList
(Object key, Collection<E> c) Converts a Collection into a cacheable List.Copy constructor. -
Method Summary
Methods inherited from class java.util.ArrayList
add, add, addAll, addAll, addFirst, addLast, clear, contains, ensureCapacity, equals, forEach, get, getFirst, getLast, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, removeFirst, removeIf, removeLast, removeRange, replaceAll, retainAll, set, size, sort, spliterator, subList, toArray, toArray, trimToSize
Methods inherited from class java.util.AbstractCollection
containsAll, toString
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArray
Methods inherited from interface java.util.List
containsAll, reversed
-
Constructor Details
-
CacheableList
-
CacheableList
Converts a Collection into a cacheable List.- Parameters:
key
- the cache keyc
- the Collection
-
CacheableList
Copy constructor.- Parameters:
cc
- the original CacheableCollection
-
-
Method Details
-
cacheKey
-
clone
Description copied from interface:CacheableCollection
Creates a copy of the collection.
-