Class SimpleFileSystemContentStorage
java.lang.Object
com.flowable.content.engine.impl.AbstractContentStorage
com.flowable.content.engine.impl.fs.SimpleFileSystemContentStorage
- All Implemented Interfaces:
org.flowable.content.api.ContentStorage
public class SimpleFileSystemContentStorage
extends AbstractContentStorage
implements org.flowable.content.api.ContentStorage
(Very) simple implementation of the
ContentStorage
that relies on the passed metadata to store content.
Under a root folder, a division between 'task' and 'process-instance' content is made. New content gets a new UUID assigned and is placed in one of these folders.
The id of the returned ContentObject
indicates in which folder it is stored.- Author:
- Joram Barrez
-
Nested Class Summary
Nested classes/interfaces inherited from class com.flowable.content.engine.impl.AbstractContentStorage
AbstractContentStorage.MapBasedContentObjectStorageMetadata
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected File
protected File
protected File
protected File
protected File
Fields inherited from class com.flowable.content.engine.impl.AbstractContentStorage
CASE_PREFIX, PROCESS_INSTANCE_PREFIX, TASK_PREFIX, TYPE_CASE_INSTANCE, TYPE_PROCESS_INSTANCE, TYPE_TASK, TYPE_UNCATEGORIZED, UNCATEGORIZED_PREFIX
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.flowable.content.api.ContentObject
createContentObject
(InputStream contentStream, org.flowable.content.api.ContentObjectStorageMetadata metaData) protected File
createOrGetFolderBasedOnMetaData
(org.flowable.content.api.ContentObjectStorageMetadata metaData) void
protected File
getContentFile
(String id) protected File
getContentFile
(org.flowable.content.api.ContentObjectStorageMetadata metaData, String contentId) org.flowable.content.api.ContentObject
protected File
internalCreateOrGetFolder
(File parentFolder, String id) org.flowable.content.api.ContentObject
updateContentObject
(String id, InputStream contentStream, org.flowable.content.api.ContentObjectStorageMetadata metaData) protected File
validateOrCreateFolder
(String folderName) protected void
Methods inherited from class com.flowable.content.engine.impl.AbstractContentStorage
convertMetaDataToMap, createContentObject, determineType, generateContentId, updateContentObject
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.flowable.content.api.ContentStorage
createContentObject, updateContentObject
-
Field Details
-
contentFolderRoot
-
taskFolder
-
processInstanceFolder
-
caseFolder
-
uncategorizedFolder
-
-
Constructor Details
-
SimpleFileSystemContentStorage
-
-
Method Details
-
validateOrCreateSubfolders
protected void validateOrCreateSubfolders() -
validateOrCreateFolder
-
createContentObject
public org.flowable.content.api.ContentObject createContentObject(InputStream contentStream, org.flowable.content.api.ContentObjectStorageMetadata metaData) - Specified by:
createContentObject
in interfaceorg.flowable.content.api.ContentStorage
-
updateContentObject
public org.flowable.content.api.ContentObject updateContentObject(String id, InputStream contentStream, org.flowable.content.api.ContentObjectStorageMetadata metaData) - Specified by:
updateContentObject
in interfaceorg.flowable.content.api.ContentStorage
-
getContentObject
- Specified by:
getContentObject
in interfaceorg.flowable.content.api.ContentStorage
-
getContentFile
-
getMetaData
- Specified by:
getMetaData
in interfaceorg.flowable.content.api.ContentStorage
-
deleteContentObject
- Specified by:
deleteContentObject
in interfaceorg.flowable.content.api.ContentStorage
-
getContentStoreName
- Specified by:
getContentStoreName
in interfaceorg.flowable.content.api.ContentStorage
-
getContentFile
-
createOrGetFolderBasedOnMetaData
protected File createOrGetFolderBasedOnMetaData(org.flowable.content.api.ContentObjectStorageMetadata metaData) -
internalCreateOrGetFolder
-