public class HippoFolder extends HippoItem implements HippoFolderBean
HippoItem.ComparatorMap
Modifier and Type | Field and Description |
---|---|
protected ArrayList<HippoDocumentBean> |
hippoDocuments |
protected ArrayList<HippoFolderBean> |
hippoFolders |
comparePath, detached, displayName, localizedName, name, node, objectConverter, path, valueProvider
Constructor and Description |
---|
HippoFolder() |
Modifier and Type | Method and Description |
---|---|
<T> HippoDocumentIterator<T> |
getDocumentIterator(Class<T> beanMappingClass)
Lazy loading iterator that fetches Documents only when asked for it.
|
List<HippoDocumentBean> |
getDocuments()
This method returns the
List of HippoDocumentBean s in the order they are in the repository. |
List<HippoDocumentBean> |
getDocuments(boolean sorted)
This method enables to get the
List of HippoDocumentBean s according their Comparable.compareTo(Object) . |
<T> List<T> |
getDocuments(Class<T> beanMappingClass)
Facility method to get all documents directly below this folder that result in a HippoBean of class or subclass clazz.
|
List<HippoDocumentBean> |
getDocuments(int from,
int to)
Returns a view of the portion of the list of HippoDocumentBean between the specified
from , inclusive, and to |
List<HippoDocumentBean> |
getDocuments(int from,
int to,
boolean sorted)
Returns a view of the portion of the list of HippoDocumentBean between the specified
from , inclusive, and to |
int |
getDocumentSize() |
List<HippoFolderBean> |
getFolders() |
List<HippoFolderBean> |
getFolders(boolean sorted) |
Locale |
getLocale()
Returns the
Locale for content bean. |
String |
getLocaleString()
Return string expression of the locale for content bean.
|
attach, compareTo, detach, equalCompare, equals, getAvailableTranslations, getBean, getBean, getBeanByUUID, getCanonicalBean, getCanonicalPath, getCanonicalUUID, getChildBeans, getChildBeans, getChildBeansByName, getChildBeansByName, getComparePath, getDisplayName, getEqualComparator, getIdentifier, getLinkedBean, getLinkedBeans, getLocalizedName, getName, getNode, getObjectConverter, getParentBean, getPath, getProperties, getProperty, getProperty, getProperty, getValueProvider, hashCode, isAncestor, isDescendant, isHippoDocumentBean, isHippoFolderBean, isLeaf, isSelf, setComparePath, setDisplayName, setIdentifier, setLocalizedName, setName, setNode, setObjectConverter, setPath
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
equalCompare, getAvailableTranslations, getBean, getBean, getBeanByUUID, getCanonicalBean, getCanonicalPath, getCanonicalUUID, getChildBeans, getChildBeans, getChildBeansByName, getChildBeansByName, getDisplayName, getEqualComparator, getLinkedBean, getLinkedBeans, getLocalizedName, getName, getNode, getParentBean, getPath, getProperties, getProperty, getProperty, getProperty, getValueProvider, isAncestor, isDescendant, isHippoDocumentBean, isHippoFolderBean, isLeaf, isSelf
getIdentifier, setIdentifier
getObjectConverter, setObjectConverter
compareTo
protected ArrayList<HippoFolderBean> hippoFolders
protected ArrayList<HippoDocumentBean> hippoDocuments
public String getLocaleString()
HippoTranslated
null
is returnedgetLocaleString
in interface HippoTranslated
null
when missingpublic Locale getLocale()
HippoTranslated
getLocale
in interface HippoTranslated
Locale
for content bean and null
when missingpublic List<HippoFolderBean> getFolders()
getFolders
in interface HippoFolderBean
HippoFolderBean
below this HippoFolderBean
and an empty list of no folders presentpublic List<HippoFolderBean> getFolders(boolean sorted)
getFolders
in interface HippoFolderBean
sorted
- if true, the list of folder will be returned sorted by their default Comparable.compareTo(Object)
HippoFolderBean
below this HippoFolderBean
and an empty list if no folders presentpublic int getDocumentSize()
getDocumentSize
in interface HippoFolderBean
public List<HippoDocumentBean> getDocuments()
HippoFolderBean
List
of HippoDocumentBean
s in the order they are in the repository. If you need the List
to be sorted according
the Comparable.compareTo(Object)
, use HippoFolderBean.getDocuments(boolean)
with arg true
note when only a subset of the documents is needed, and the total number is large, better use HippoFolderBean.getDocumentIterator(Class)
as this is a lazy proxied iteratorgetDocuments
in interface HippoFolderBean
HippoDocumentBean
s below this HippoFolderBean
and an empty list if no documents presentpublic List<HippoDocumentBean> getDocuments(int from, int to)
HippoFolderBean
from
, inclusive, and to, exclusive. (If from and to are equal, the returned list is empty.)
note when only a subset of the documents is needed, and the total number is large, better use HippoFolderBean.getDocumentIterator(Class)
as this is a lazy proxied iterator
getDocuments
in interface HippoFolderBean
from
- (inclusive)to
- (exclusive)HippoDocumentBean
below this HippoFolderBean
and an empty list when original list is empty or invalid rangepublic List<HippoDocumentBean> getDocuments(int from, int to, boolean sorted)
HippoFolderBean
from
, inclusive, and to, exclusive. (If from and to are equal, the returned list is empty.)
note when only a subset of unsorted documents is needed, and the total number is large, better use HippoFolderBean.getDocumentIterator(Class)
as this is a lazy proxied iterator
getDocuments
in interface HippoFolderBean
from
- (inclusive)to
- (exclusive)sorted
- boolean whether list to get sublist from needs to be sortedHippoDocumentBean
below this HippoFolderBean
and an empty list when original list is empty or invalid rangepublic <T> List<T> getDocuments(Class<T> beanMappingClass)
HippoFolderBean
HippoFolderBean.getDocumentIterator(Class)
as this is a lazy proxied iteratorgetDocuments
in interface HippoFolderBean
T
- Any Object that implements a HippoDocumentBeanbeanMappingClass
- a class implementing HippoDocumentBean
. This functions as a filter
public List<HippoDocumentBean> getDocuments(boolean sorted)
HippoFolderBean
List
of HippoDocumentBean
s according their Comparable.compareTo(Object)
. If you need the List
to be ordered the way the documents are ordered in the repository, use HippoFolderBean.getDocuments()
.
note when only a subset of unsorted documents is needed, and the total number is large, better use HippoFolderBean.getDocumentIterator(Class)
as this is a lazy proxied iteratorgetDocuments
in interface HippoFolderBean
sorted
- indicates whether the List should be sortedsorted
is true, the sorted list of HippoDocumentBean
s below this HippoFolderBean
, where the sorting is according Comparable.compareTo(Object)
, If sorted
is false, the same list as HippoFolderBean.getDocuments()
is returned. An empty list is returned if no documents are present.public <T> HippoDocumentIterator<T> getDocumentIterator(Class<T> beanMappingClass)
HippoFolderBean
HippoFolderBean.getDocuments()
methods (also with arguments) as they fetch all HippoDocumentBeans directly.getDocumentIterator
in interface HippoFolderBean
T
- Any Object that implements a HippoDocumentBeanbeanMappingClass
- a class implementing HippoDocumentBean
. This functions as a filter
Copyright © 2008–2016 Hippo B.V. (http://www.onehippo.com). All rights reserved.