public abstract class AbstractVirtualFolderItemFactory extends Object implements VirtualFolderItemFactory
FileSystemItemFactory for a virtual FolderItem.| Constructor and Description |
|---|
AbstractVirtualFolderItemFactory() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canHandleFileSystemItemId(String id)
Returns true if the given
FileSystemItem id can be handled by this factory. |
boolean |
exists(String id,
Principal principal)
Returns true if a
FileSystemItem with the given id exists for the given principal. |
DocumentModel |
getDocumentByFileSystemId(String id,
Principal principal)
Deprecated.
|
FileSystemItem |
getFileSystemItem(DocumentModel doc)
Gets the
FileSystemItem for the given DocumentModel. |
FileSystemItem |
getFileSystemItem(DocumentModel doc,
boolean includeDeleted)
Gets the
FileSystemItem for the given DocumentModel. |
FileSystemItem |
getFileSystemItem(DocumentModel doc,
boolean includeDeleted,
boolean relaxSyncRootConstraint)
Gets the
FileSystemItem for the given DocumentModel. |
FileSystemItem |
getFileSystemItem(DocumentModel doc,
FolderItem parentItem)
Gets the
FileSystemItem for the given DocumentModel forcing its parent id with the given id. |
FileSystemItem |
getFileSystemItem(DocumentModel doc,
FolderItem parentItem,
boolean includeDeleted)
Gets the
FileSystemItem for the given DocumentModel forcing its parent id with the given id. |
FileSystemItem |
getFileSystemItem(DocumentModel doc,
FolderItem parentItem,
boolean includeDeleted,
boolean relaxSyncRootConstraint)
Gets the
FileSystemItem for the given DocumentModel forcing its parent id with the given id. |
FileSystemItem |
getFileSystemItemById(String id,
Principal principal)
Gets the
FileSystemItem with the given id using a core session fetched with the given principal. |
FileSystemItem |
getFileSystemItemById(String id,
String parentId,
Principal principal)
Gets the
FileSystemItem with the given id and parent id using a core session fetched with the given
principal. |
String |
getFolderName() |
String |
getName()
Gets the factory unique name.
|
abstract FolderItem |
getVirtualFolderItem(Principal principal)
Returns the (unique) virtual
FolderItem. |
void |
handleParameters(Map<String,String> parameters)
Handles the factory parameters contributed through the
fileSystemItemFactory contribution. |
boolean |
isFileSystemItem(DocumentModel doc)
Returns true if the given
DocumentModel is adaptable as a FileSystemItem. |
boolean |
isFileSystemItem(DocumentModel doc,
boolean includeDeleted)
Returns true if the given
DocumentModel is adaptable as a FileSystemItem. |
boolean |
isFileSystemItem(DocumentModel doc,
boolean includeDeleted,
boolean relaxSyncRootConstraint)
Returns true if the given
DocumentModel is adaptable as a FileSystemItem. |
void |
setFolderName(String folderName) |
void |
setName(String name)
Sets the factory unique name.
|
public abstract FolderItem getVirtualFolderItem(Principal principal) throws ClientException
VirtualFolderItemFactoryFolderItem.getVirtualFolderItem in interface VirtualFolderItemFactoryClientExceptionpublic String getName()
FileSystemItemFactorygetName in interface FileSystemItemFactorypublic void setName(String name)
FileSystemItemFactorysetName in interface FileSystemItemFactorypublic void handleParameters(Map<String,String> parameters) throws ClientException
FileSystemItemFactoryfileSystemItemFactory contribution.handleParameters in interface FileSystemItemFactoryClientExceptionpublic boolean isFileSystemItem(DocumentModel doc) throws ClientException
FileSystemItemFactoryDocumentModel is adaptable as a FileSystemItem.isFileSystemItem in interface FileSystemItemFactoryClientExceptionFileSystemItemFactory.isFileSystemItem(DocumentModel, boolean)public boolean isFileSystemItem(DocumentModel doc, boolean includeDeleted) throws ClientException
FileSystemItemFactoryDocumentModel is adaptable as a FileSystemItem. If
includeDeleted is true no filter is applied on the "deleted" life cycle state, else if the document is in
this state it is not considered as adaptable as a FileSystemItem, thus the method returns false.isFileSystemItem in interface FileSystemItemFactoryClientExceptionpublic boolean isFileSystemItem(DocumentModel doc, boolean includeDeleted, boolean relaxSyncRootConstraint) throws ClientException
FileSystemItemFactoryDocumentModel is adaptable as a FileSystemItem.
If includeDeleted is true no filter is applied on the "deleted" life cycle state, else if the document is
in this state it is not considered as adaptable as a FileSystemItem, thus the method returns false.
If relaxSyncRootConstraint is true no filter is applied on the synchronization root aspect for the
current user.
isFileSystemItem in interface FileSystemItemFactoryClientExceptionpublic FileSystemItem getFileSystemItem(DocumentModel doc) throws ClientException
FileSystemItemFactoryFileSystemItem for the given DocumentModel.getFileSystemItem in interface FileSystemItemFactoryFileSystemItem or null if the DocumentModel is not adaptable as a
FileSystemItemClientExceptionFileSystemItemFactory.isFileSystemItem(DocumentModel),
FileSystemItemFactory.getFileSystemItem(DocumentModel, boolean)public FileSystemItem getFileSystemItem(DocumentModel doc, boolean includeDeleted) throws ClientException
FileSystemItemFactoryFileSystemItem for the given DocumentModel. If includeDeleted is true no filter
is applied on the "deleted" life cycle state, else if the document is in this state it is not considered as
adaptable as a FileSystemItem, thus the method returns null.getFileSystemItem in interface FileSystemItemFactoryFileSystemItem or null if the DocumentModel is not adaptable as a
FileSystemItemClientException#isFileSystemItem(DocumentModel, boolean))public FileSystemItem getFileSystemItem(DocumentModel doc, boolean includeDeleted, boolean relaxSyncRootConstraint) throws ClientException
FileSystemItemFactoryFileSystemItem for the given DocumentModel.
If includeDeleted is true no filter is applied on the "deleted" life cycle state, else if the document is
in this state it is not considered as adaptable as a FileSystemItem, thus the method returns null.
If relaxSyncRootConstraint is true no filter is applied on the synchronization root aspect for the
current user.
getFileSystemItem in interface FileSystemItemFactoryFileSystemItem or null if the DocumentModel is not adaptable as a
FileSystemItemClientException#isFileSystemItem(DocumentModel, boolean, boolean))public FileSystemItem getFileSystemItem(DocumentModel doc, FolderItem parentItem) throws ClientException
FileSystemItemFactoryFileSystemItem for the given DocumentModel forcing its parent id with the given id.getFileSystemItem in interface FileSystemItemFactoryFileSystemItem or null if the DocumentModel is not adaptable as a
FileSystemItemClientExceptionFileSystemItemFactory.isFileSystemItem(DocumentModel),
#getFileSystemItem(DocumentModel, String, boolean)public FileSystemItem getFileSystemItem(DocumentModel doc, FolderItem parentItem, boolean includeDeleted) throws ClientException
FileSystemItemFactoryFileSystemItem for the given DocumentModel forcing its parent id with the given id. If
includeDeleted is true no filter is applied on the "deleted" life cycle state, else if the document is in
this state it is not considered as adaptable as a FileSystemItem, thus the method returns null.getFileSystemItem in interface FileSystemItemFactoryFileSystemItem or null if the DocumentModel is not adaptable as a
FileSystemItemClientExceptionFileSystemItemFactory.isFileSystemItem(DocumentModel, boolean)public FileSystemItem getFileSystemItem(DocumentModel doc, FolderItem parentItem, boolean includeDeleted, boolean relaxSyncRootConstraint) throws ClientException
FileSystemItemFactoryFileSystemItem for the given DocumentModel forcing its parent id with the given id.
If includeDeleted is true no filter is applied on the "deleted" life cycle state, else if the document is
in this state it is not considered as adaptable as a FileSystemItem, thus the method returns null.
If relaxSyncRootConstraint is true no filter is applied on the synchronization root aspect for the
current user.
getFileSystemItem in interface FileSystemItemFactoryFileSystemItem or null if the DocumentModel is not adaptable as a
FileSystemItemClientExceptionFileSystemItemFactory.isFileSystemItem(DocumentModel, boolean, boolean)public boolean canHandleFileSystemItemId(String id)
FileSystemItemFactoryFileSystemItem id can be handled by this factory. It is typically the case when
the factory has been responsible for generating the FileSystemItem.canHandleFileSystemItemId in interface FileSystemItemFactorypublic boolean exists(String id, Principal principal) throws ClientException
FileSystemItemFactoryFileSystemItem with the given id exists for the given principal.exists in interface FileSystemItemFactoryClientExceptionpublic FileSystemItem getFileSystemItemById(String id, Principal principal) throws ClientException
FileSystemItemFactoryFileSystemItem with the given id using a core session fetched with the given principal.getFileSystemItemById in interface FileSystemItemFactoryFileSystemItem or null if none matches the given idClientExceptionpublic FileSystemItem getFileSystemItemById(String id, String parentId, Principal principal) throws ClientException
FileSystemItemFactoryFileSystemItem with the given id and parent id using a core session fetched with the given
principal.getFileSystemItemById in interface FileSystemItemFactoryFileSystemItem or null if none matches the given id and parent idClientException@Deprecated public DocumentModel getDocumentByFileSystemId(String id, Principal principal) throws ClientException
FileSystemItemFactoryDocumentModel bound to the given FileSystemItem id using a core session fetched with the
given principal.getDocumentByFileSystemId in interface FileSystemItemFactoryDocumentModelClientExceptionpublic String getFolderName()
getFolderName in interface VirtualFolderItemFactorypublic void setFolderName(String folderName)
setFolderName in interface VirtualFolderItemFactoryCopyright © 2015 Nuxeo SA. All rights reserved.