Package org.craftercms.commons.file.blob
Interface BlobStore
- All Known Implementing Classes:
AbstractBlobStore
,AwsS3BlobStore
public interface BlobStore
Defines the operations to handle blob files
- Since:
- 3.1.6
- Author:
- joseross
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptiongetId()
Returns the unique id of the storeorg.springframework.core.io.Resource
getResource
(String path, Blob blob) Resolves the given blob to a readable resourcevoid
init
(org.apache.commons.configuration2.HierarchicalConfiguration<org.apache.commons.configuration2.tree.ImmutableNode> config) Performs all setup needed with the given configurationboolean
isCompatible
(String path) Indicates if the given path is compatible with the store
-
Field Details
-
CONFIG_KEY_ID
- See Also:
-
CONFIG_KEY_PATTERN
- See Also:
-
CONFIG_KEY_MAPPING
- See Also:
-
CONFIG_KEY_MAPPING_PUBLISHING_TARGET
- See Also:
-
CONFIG_KEY_MAPPING_STORE_TARGET
- See Also:
-
CONFIG_KEY_MAPPING_PREFIX
- See Also:
-
CONFIG_KEY_CONFIGURATION
- See Also:
-
-
Method Details
-
init
void init(org.apache.commons.configuration2.HierarchicalConfiguration<org.apache.commons.configuration2.tree.ImmutableNode> config) throws ConfigurationException Performs all setup needed with the given configuration- Parameters:
config
- the configuration object- Throws:
ConfigurationException
- is any error occurs
-
getId
String getId()Returns the unique id of the store- Returns:
- the id
-
isCompatible
Indicates if the given path is compatible with the store- Parameters:
path
- path to check- Returns:
- true if the path is compatible
-
getResource
Resolves the given blob to a readable resource- Parameters:
path
- the path of the resourceblob
- the blob file- Returns:
- the resource object
-