public interface Store
| Modifier and Type | Method and Description |
|---|---|
void |
createDocument(String documentPath,
String content)
Creates a document.
|
void |
createDocuments(List<org.springframework.extensions.surf.util.Pair<String,org.dom4j.Document>> paths)
Creates multiple XML documents at the specified paths.
|
boolean |
exists()
Determines whether the store actually exists
|
String[] |
getAllDocumentPaths()
Gets the paths of all documents in this store
|
String |
getBasePath()
Gets the base path of the store
|
String[] |
getDescriptionDocumentPaths()
Gets the paths of all Web Script description documents in this store
|
InputStream |
getDocument(String documentPath)
Gets a document.
|
String[] |
getDocumentPaths(String path,
boolean includeSubPaths,
String documentPattern)
Gets the paths of given document pattern within given path/sub-paths in this store
|
String[] |
getDocumentPaths(String path,
String filePathPattern)
Gets the paths matching a given file path pattern in this store.
|
String[] |
getScriptDocumentPaths(WebScript script)
Gets the paths of all implementation files for a given Web Script
|
ScriptLoader |
getScriptLoader()
Gets the script loader for this store
|
freemarker.cache.TemplateLoader |
getTemplateLoader()
Gets the template loader for this store
|
boolean |
hasDocument(String documentPath)
Determines if the document exists.
|
void |
init()
Initialise Store (called once)
|
boolean |
isReadOnly()
Indicates whether or not this store can be written to.
|
boolean |
isSecure()
Returns true if this store is considered secure - i.e.
|
long |
lastModified(String documentPath)
Gets the last modified timestamp for the document.
|
boolean |
removeDocument(String documentPath)
Removes an existing document.
|
void |
updateDocument(String documentPath,
String content)
Updates an existing document.
|
void init()
boolean exists()
String getBasePath()
boolean isSecure()
String[] getDocumentPaths(String path, boolean includeSubPaths, String documentPattern) throws IOException
path - start pathincludeSubPaths - if true, include sub-pathsdocumentPattern - document name, allows wildcards, eg. *.ftl or my*.ftlIOExceptionString[] getDocumentPaths(String path, String filePathPattern) throws IOException
path - start pathfilePathPattern - file path pattern string, allows wildcards, eg. *.ftl or my*.ftl or *\/a\/*.xmlIOExceptionString[] getDescriptionDocumentPaths() throws IOException
IOExceptionString[] getScriptDocumentPaths(WebScript script) throws IOException
script - web scriptIOExceptionString[] getAllDocumentPaths()
long lastModified(String documentPath) throws IOException
documentPath - document path to an existing documentIOException - if the document does not exist in the storeboolean hasDocument(String documentPath) throws IOException
documentPath - document pathIOException - Signals that an I/O exception has occurred.InputStream getDocument(String documentPath) throws IOException
documentPath - document pathIOException - if the document does not exist in the storevoid createDocument(String documentPath, String content) throws IOException
documentPath - document pathcontent - content of the document to writeIOException - if the document already exists or the create failsvoid createDocuments(List<org.springframework.extensions.surf.util.Pair<String,org.dom4j.Document>> paths) throws IOException
paths - list of path, document pairsIOException - if a document already exists or a create failsvoid updateDocument(String documentPath, String content) throws IOException
documentPath - document pathcontent - content to update the document withIOException - if the document does not exist or the update failsboolean removeDocument(String documentPath) throws IOException
documentPath - document pathIOException - if the document does not exist or the remove failsfreemarker.cache.TemplateLoader getTemplateLoader()
ScriptLoader getScriptLoader()
boolean isReadOnly()
true If the store cannot be written to and false otherwise.Copyright © 2005–2021 Alfresco Software. All rights reserved.