public class FolderHierarchyService extends java.lang.Object implements IInternalFolderHierarchy
Modifier and Type | Field and Description |
---|---|
protected Container |
container |
protected BmContext |
context |
protected FolderHierarchyEventProducer |
eventProducer |
protected FolderHierarchyStore |
folderStore |
protected static java.util.List<IFolderHook> |
hooks |
protected static org.slf4j.Logger |
logger |
protected java.lang.String |
mailboxUid |
protected SecurityContext |
securityContext |
protected FolderStoreService |
storeService |
Constructor and Description |
---|
FolderHierarchyService(BmContext context,
Container container,
java.lang.String mailboxUid) |
Modifier and Type | Method and Description |
---|---|
java.util.List<java.lang.String> |
allUids() |
ItemValue<Folder> |
byContentUri(java.lang.String uri) |
ItemValue<Folder> |
byId(java.lang.Long id) |
java.util.List<ItemValue<Folder>> |
byParentId(java.lang.Long pid) |
ItemValue<Folder> |
byUid(java.lang.Long uid) |
ContainerChangelog |
changelog(java.lang.Long since)
ChangeLog of the container since
|
ContainerChangeset<java.lang.String> |
changeset(java.lang.Long since)
ChangeSet of the container since
|
ContainerChangeset<java.lang.Long> |
changesetById(java.lang.Long since)
ChangeSet of the container since
|
void |
create(java.lang.String uid,
Folder folder)
Creates a new
Folder entry. |
ItemValue<Folder> |
createFolder(ContainerDescriptor cd,
java.lang.Long parentId)
Creates a folder corresponding to the given container
Not exposed over http
|
void |
delete(java.lang.String uid)
Delete
Folder entry |
void |
deleteAll()
Delete the entire hierarchy
|
ItemValue<Folder> |
getComplete(java.lang.String uid)
Fetch a
Folder from its unique uid |
protected static java.util.List<IFolderHook> |
getHooks() |
java.util.List<ItemValue<Folder>> |
multipleGet(java.util.List<java.lang.String> uids)
Fetch multiple
Folder s from theirs uniques uids |
void |
reset() |
ListResult<ItemValue<Folder>> |
search(FolderQuery query)
Searches for the
Folder s items in the container using the given
query |
void |
update(java.lang.String uid,
Folder folder)
Modifies an existing
Folder entry. |
protected static final org.slf4j.Logger logger
protected final FolderHierarchyStore folderStore
protected final FolderStoreService storeService
protected final BmContext context
protected final java.lang.String mailboxUid
protected final SecurityContext securityContext
protected final Container container
protected final FolderHierarchyEventProducer eventProducer
protected static final java.util.List<IFolderHook> hooks
public FolderHierarchyService(BmContext context, Container container, java.lang.String mailboxUid) throws ServerFault
ServerFault
public void create(java.lang.String uid, Folder folder) throws ServerFault
IInternalFolderHierarchy
Folder
entry.create
in interface IInternalFolderHierarchy
uid
- uid of the entryfolder
- value of the entryServerFault
public void update(java.lang.String uid, Folder folder) throws ServerFault
IInternalFolderHierarchy
Folder
entry.update
in interface IInternalFolderHierarchy
uid
- uid of the entryfolder
- value of the entryServerFault
public ItemValue<Folder> getComplete(java.lang.String uid) throws ServerFault
IFolderHierarchy
Folder
from its unique uidgetComplete
in interface IFolderHierarchy
ItemValue
ServerFault
public java.util.List<ItemValue<Folder>> multipleGet(java.util.List<java.lang.String> uids) throws ServerFault
IFolderHierarchy
Folder
s from theirs uniques uidsmultipleGet
in interface IFolderHierarchy
List>
ServerFault
public void delete(java.lang.String uid) throws ServerFault
IInternalFolderHierarchy
Folder
entrydelete
in interface IInternalFolderHierarchy
ServerFault
public void deleteAll() throws ServerFault
IInternalFolderHierarchy
deleteAll
in interface IInternalFolderHierarchy
ServerFault
protected static java.util.List<IFolderHook> getHooks()
public ContainerChangelog changelog(java.lang.Long since) throws ServerFault
IFolderHierarchy
changelog
in interface IFolderHierarchy
since
- timestamp of first changes we want to retrieveContainerChangelog
ServerFault
public ContainerChangeset<java.lang.String> changeset(java.lang.Long since) throws ServerFault
IFolderHierarchy
changeset
in interface IFolderHierarchy
since
- timestamp of first changes we want to retrieveServerFault
public ContainerChangeset<java.lang.Long> changesetById(java.lang.Long since) throws ServerFault
IFolderHierarchy
changesetById
in interface IFolderHierarchy
since
- timestamp of first changes we want to retrieveServerFault
public ItemValue<Folder> byContentUri(java.lang.String uri) throws ServerFault
byContentUri
in interface IFolderHierarchy
ServerFault
public java.util.List<ItemValue<Folder>> byParentId(java.lang.Long pid) throws ServerFault
byParentId
in interface IFolderHierarchy
ServerFault
public ItemValue<Folder> byUid(java.lang.Long uid) throws ServerFault
byUid
in interface IFolderHierarchy
ServerFault
public ItemValue<Folder> byId(java.lang.Long id) throws ServerFault
byId
in interface IFolderHierarchy
ServerFault
public ListResult<ItemValue<Folder>> search(FolderQuery query) throws ServerFault
IFolderHierarchy
Folder
s items in the container using the given
querysearch
in interface IFolderHierarchy
query
- the search criteriaFolder
objectsServerFault
public ItemValue<Folder> createFolder(ContainerDescriptor cd, java.lang.Long parentId) throws ServerFault
IInternalFolderHierarchy
createFolder
in interface IInternalFolderHierarchy
cd
- the containerparentId
- the parent idServerFault
public java.util.List<java.lang.String> allUids() throws ServerFault
allUids
in interface IFolderHierarchy
ServerFault
public void reset() throws ServerFault
reset
in interface IFolderHierarchy
ServerFault
Copyright © 2021. All Rights Reserved.