org.nuxeo.ecm.core.api.repository.cache
Class CachingDocumentList
java.lang.Object
org.nuxeo.ecm.core.api.repository.cache.CachingDocumentList
- All Implemented Interfaces:
- Serializable, Iterable<DocumentModel>, Collection<DocumentModel>, List<DocumentModel>, DocumentModelList
public class CachingDocumentList
- extends Object
- implements DocumentModelList
A document list that uses document cached from the document cache.
This is not using the children cache. If you need to cache getChildren calls it is better to use
the DocumentChildrenList
which is caching children lists
- Author:
- Bogdan Stefanescu
- See Also:
- Serialized Form
CachingDocumentList
public CachingDocumentList(DocumentModelCache cache,
List<DocumentModel> list)
add
public boolean add(DocumentModel o)
- Specified by:
add
in interface Collection<DocumentModel>
- Specified by:
add
in interface List<DocumentModel>
add
public void add(int index,
DocumentModel element)
- Specified by:
add
in interface List<DocumentModel>
addAll
public boolean addAll(Collection<? extends DocumentModel> c)
- Specified by:
addAll
in interface Collection<DocumentModel>
- Specified by:
addAll
in interface List<DocumentModel>
addAll
public boolean addAll(int index,
Collection<? extends DocumentModel> c)
- Specified by:
addAll
in interface List<DocumentModel>
clear
public void clear()
- Specified by:
clear
in interface Collection<DocumentModel>
- Specified by:
clear
in interface List<DocumentModel>
contains
public boolean contains(Object o)
- Specified by:
contains
in interface Collection<DocumentModel>
- Specified by:
contains
in interface List<DocumentModel>
containsAll
public boolean containsAll(Collection<?> c)
- Specified by:
containsAll
in interface Collection<DocumentModel>
- Specified by:
containsAll
in interface List<DocumentModel>
get
public DocumentModel get(int index)
- Specified by:
get
in interface List<DocumentModel>
indexOf
public int indexOf(Object o)
- Specified by:
indexOf
in interface List<DocumentModel>
isEmpty
public boolean isEmpty()
- Specified by:
isEmpty
in interface Collection<DocumentModel>
- Specified by:
isEmpty
in interface List<DocumentModel>
iterator
public Iterator<DocumentModel> iterator()
- Specified by:
iterator
in interface Iterable<DocumentModel>
- Specified by:
iterator
in interface Collection<DocumentModel>
- Specified by:
iterator
in interface List<DocumentModel>
lastIndexOf
public int lastIndexOf(Object o)
- Specified by:
lastIndexOf
in interface List<DocumentModel>
listIterator
public ListIterator<DocumentModel> listIterator()
- Specified by:
listIterator
in interface List<DocumentModel>
listIterator
public ListIterator<DocumentModel> listIterator(int index)
- Specified by:
listIterator
in interface List<DocumentModel>
remove
public DocumentModel remove(int index)
- Specified by:
remove
in interface List<DocumentModel>
remove
public boolean remove(Object o)
- Specified by:
remove
in interface Collection<DocumentModel>
- Specified by:
remove
in interface List<DocumentModel>
removeAll
public boolean removeAll(Collection<?> c)
- Specified by:
removeAll
in interface Collection<DocumentModel>
- Specified by:
removeAll
in interface List<DocumentModel>
retainAll
public boolean retainAll(Collection<?> c)
- Specified by:
retainAll
in interface Collection<DocumentModel>
- Specified by:
retainAll
in interface List<DocumentModel>
set
public DocumentModel set(int index,
DocumentModel element)
- Specified by:
set
in interface List<DocumentModel>
size
public int size()
- Specified by:
size
in interface Collection<DocumentModel>
- Specified by:
size
in interface List<DocumentModel>
totalSize
public long totalSize()
- Description copied from interface:
DocumentModelList
- Returns the total size of the bigger list this is a part of.
- Specified by:
totalSize
in interface DocumentModelList
- Returns:
- the total size
subList
public List<DocumentModel> subList(int fromIndex,
int toIndex)
- Specified by:
subList
in interface List<DocumentModel>
toArray
public Object[] toArray()
- Specified by:
toArray
in interface Collection<DocumentModel>
- Specified by:
toArray
in interface List<DocumentModel>
toArray
public <T> T[] toArray(T[] a)
- Specified by:
toArray
in interface Collection<DocumentModel>
- Specified by:
toArray
in interface List<DocumentModel>
Copyright © 2011 Nuxeo SAS. All Rights Reserved.