Interface FileManager
- All Known Implementing Classes:
FileManagerService
public interface FileManager
File Manager.
File Manager to handle file
- Author:
- Andreas Kalogeropoulos
-
Method Summary
Modifier and TypeMethodDescriptioncreateFolder
(CoreSession documentManager, String fullname, String path, boolean overwrite) Creates a Folder.Returns a created or updated document based on the givencontext
.findExistingDocumentWithFile
(CoreSession documentManager, String path, String digest, NuxeoPrincipal principal) getCreationContainers
(CoreSession documentManager, String docType) Returns the list of document that are to be suggested to the principal of documentManager as a candidate container for a new document of type docType.getCreationContainers
(NuxeoPrincipal principal, String docType) Returns the list of document that are to be suggested to principalName as a candidate container for a new document of type docType on all registered repositories.boolean
boolean
-
Method Details
-
createOrUpdateDocument
Returns a created or updated document based on the givencontext
.The document may not be persisted according to
FileImporterContext.isPersistDocument()
. That's the caller's responsibility to actually persist the document.Note that file importers may not use
FileImporterContext.isPersistDocument()
and always persist the document.- Returns:
- the created or updated document
- Throws:
IOException
- Since:
- 10.10
- See Also:
-
createFolder
DocumentModel createFolder(CoreSession documentManager, String fullname, String path, boolean overwrite) throws IOException Creates a Folder.- Parameters:
fullname
- the full name of the folderpath
- the path were to create the folderoverwrite
- whether to overwrite an existing folder with the same title or not- Returns:
- the Folder Created
- Throws:
IOException
- Since:
- 9.1
-
getCreationContainers
Returns the list of document that are to be suggested to principalName as a candidate container for a new document of type docType on all registered repositories.- Returns:
- the list of candidate containers
-
getCreationContainers
Returns the list of document that are to be suggested to the principal of documentManager as a candidate container for a new document of type docType.- Returns:
- the list of candidate containers
-
findExistingDocumentWithFile
List<DocumentLocation> findExistingDocumentWithFile(CoreSession documentManager, String path, String digest, NuxeoPrincipal principal) -
isUnicityEnabled
boolean isUnicityEnabled() -
getFields
-
getDigestAlgorithm
String getDigestAlgorithm() -
isDigestComputingEnabled
boolean isDigestComputingEnabled()
-