public class DbFolderModule extends Object implements FolderModule
| Constructor and Description |
|---|
DbFolderModule() |
| Modifier and Type | Method and Description |
|---|---|
void |
copy(String token,
String fldId,
String dstId)
Copy a folder to another location in the repository.
|
Folder |
create(String token,
Folder fld)
Create a new folder in the repository.
|
void |
delete(String token,
String fldId)
Delete a folder the repository.
|
void |
extendedCopy(String token,
String fldId,
String dstId,
ExtendedAttributes extAttr)
Copy a folder to another location in the repository.
|
List<Folder> |
getChildren(String token,
String fldId)
Retrieve a list of children folders from an existing one.
|
List<Folder> |
getChilds(String token,
String fldId)
Deprecated.
|
ContentInfo |
getContentInfo(String token,
String fldId)
Retrive the content info of the folder: number of folders, number of documents, and total size.
|
String |
getPath(String token,
String uuid)
Get the folder path from a UUID
|
Folder |
getProperties(String token,
String fldId)
Obtains properties from a previously created folder.
|
boolean |
isValid(String token,
String fldId)
Test if a folder path is valid.
|
void |
move(String token,
String fldId,
String dstId)
Move a folder to another location in the repository.
|
void |
purge(String token,
String fldId)
Deletes definitively a folder from the repository.
|
Folder |
rename(String token,
String fldId,
String newName)
Rename a folder in the repository.
|
public Folder create(String token, Folder fld) throws PathNotFoundException, ItemExistsException, AccessDeniedException, RepositoryException, DatabaseException, ExtensionException, AutomationException
FolderModulecreate in interface FolderModulefld - A folder object with the new folder properties.PathNotFoundException - If the parent folder doesn't exist.ItemExistsException - If there is already a folder in the repository with the same name in the same path.AccessDeniedException - If there is any security problem: you can't modify the parent folder because of
lack of permissions.RepositoryException - If there is any general repository problem.DatabaseExceptionExtensionExceptionAutomationExceptionpublic Folder getProperties(String token, String fldId) throws AccessDeniedException, PathNotFoundException, RepositoryException, DatabaseException
FolderModulegetProperties in interface FolderModulefldId - The path that identifies an unique folder.PathNotFoundException - If the indicated folder doesn't exist.RepositoryException - If there is any general repository problem.AccessDeniedExceptionDatabaseExceptionpublic void delete(String token, String fldId) throws LockException, PathNotFoundException, AccessDeniedException, RepositoryException, DatabaseException
FolderModuledelete in interface FolderModulefldId - The path that identifies an unique folder.LockException - Can't delete a folder with locked documents.PathNotFoundException - If there is no folder in the repository in this path.AccessDeniedException - If there is any security problem: you can't modify the folder because of lack of
permissions.RepositoryException - If there is any general repository problem.DatabaseExceptionpublic void purge(String token, String fldId) throws LockException, PathNotFoundException, AccessDeniedException, RepositoryException, DatabaseException
FolderModulepurge in interface FolderModulefldId - The path that identifies an unique folder.LockException - Can't delete a folder with locked documents.PathNotFoundException - If there is no folder in the repository in this path.AccessDeniedException - If there is any security problem: you can't modify the folder because of lack of
permissions.RepositoryException - If there is any general repository problem.DatabaseExceptionpublic Folder rename(String token, String fldId, String newName) throws PathNotFoundException, ItemExistsException, AccessDeniedException, RepositoryException, DatabaseException
FolderModulerename in interface FolderModulefldId - The path that identifies an unique folder.newName - The new folder name.PathNotFoundException - If there is no folder in the repository in this path.ItemExistsException - If there is already a folder in the repository with the same name in the same path.AccessDeniedException - If there is any security problem: you can't modify the folder because of lack of
permissions.RepositoryException - If there is any general repository problem.DatabaseExceptionpublic void move(String token, String fldId, String dstId) throws PathNotFoundException, ItemExistsException, AccessDeniedException, RepositoryException, DatabaseException
FolderModulemove in interface FolderModulefldId - The path that identifies an unique folder.dstId - The path of the destination folder.PathNotFoundException - If the dstPath does not exists.ItemExistsException - If there is already a folder in the destination folder with the same name.AccessDeniedException - If there is any security problem: you can't modify the parent folder or the
destination folder because of lack of permissions.RepositoryException - If there is any general repository problem.DatabaseExceptionpublic void copy(String token, String fldId, String dstId) throws PathNotFoundException, ItemExistsException, AccessDeniedException, RepositoryException, IOException, AutomationException, DatabaseException, UserQuotaExceededException
FolderModulecopy in interface FolderModulefldId - The path that identifies an unique folder.dstId - The path of the destination folder.PathNotFoundException - If the dstPath does not exists.ItemExistsException - If there is already a folder in the destination folder with the same name.AccessDeniedException - If there is any security problem: you can't modify the parent folder or the
destination folder because of lack of permissions.RepositoryException - If there is any general repository problem.IOExceptionAutomationExceptionDatabaseExceptionUserQuotaExceededExceptionpublic void extendedCopy(String token, String fldId, String dstId, ExtendedAttributes extAttr) throws PathNotFoundException, ItemExistsException, AccessDeniedException, RepositoryException, IOException, AutomationException, DatabaseException, UserQuotaExceededException
FolderModuleextendedCopy in interface FolderModulefldId - The path that identifies an unique folder.dstId - The path of the destination folder.extAttr - Attributes to define what need to be duplicated.PathNotFoundException - If the dstPath does not exists.ItemExistsException - If there is already a folder in the destination folder with the same name.AccessDeniedException - If there is any security problem: you can't modify the parent folder or the
destination folder because of lack of permissions.RepositoryException - If there is any general repository problem.IOExceptionAutomationExceptionDatabaseExceptionUserQuotaExceededException@Deprecated public List<Folder> getChilds(String token, String fldId) throws AccessDeniedException, PathNotFoundException, RepositoryException, DatabaseException
FolderModulegetChilds in interface FolderModulefldId - The path that identifies an unique folder or its UUID.PathNotFoundException - If there is no folder in the repository in this pathRepositoryException - If there is any general repository problem.AccessDeniedExceptionDatabaseExceptionpublic List<Folder> getChildren(String token, String fldId) throws AccessDeniedException, PathNotFoundException, RepositoryException, DatabaseException
FolderModulegetChildren in interface FolderModulefldId - The path that identifies an unique folder or its UUID.PathNotFoundException - If there is no folder in the repository in this pathRepositoryException - If there is any general repository problem.AccessDeniedExceptionDatabaseExceptionpublic ContentInfo getContentInfo(String token, String fldId) throws AccessDeniedException, RepositoryException, PathNotFoundException, DatabaseException
FolderModulegetContentInfo in interface FolderModulefldId - The path that identifies an unique folder.AccessDeniedException - If there is any security problem: you can't access this folder because of lack of
permissions.RepositoryException - If there is any general repository problem.PathNotFoundException - If there is no folder in the repository with this path.DatabaseExceptionpublic boolean isValid(String token, String fldId) throws AccessDeniedException, PathNotFoundException, RepositoryException, DatabaseException
FolderModuleisValid in interface FolderModulefldId - The path that identifies an unique folder or its UUID.PathNotFoundException - If the node does not exists.RepositoryException - If there is any general repository problem.AccessDeniedExceptionDatabaseExceptionpublic String getPath(String token, String uuid) throws AccessDeniedException, RepositoryException, DatabaseException
FolderModulegetPath in interface FolderModuleuuid - The unique folder id.AccessDeniedException - If there is any security problem: you can't access this folder because of lack of
permissions.RepositoryException - If there is any problem.DatabaseExceptionCopyright © 2018 Open Knowledge Management System S.L.. All rights reserved.