public class FileContentManager extends java.lang.Object implements ContentReader, ContentWriter
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
FILE_CONTENT_MANAGER_PROPERTIES_FILE |
static java.lang.String |
FILE_SCHEME |
static java.lang.String |
FOLDER_CONTENT_DEFAULT_PATH |
static java.lang.String |
FOLDER_CONTENT_PATH_PROPERTY_NAME |
static java.lang.String |
NETWORK_SCHEMES |
static java.lang.String |
PREFIX |
static java.lang.String |
SUFFIX |
| Constructor and Description |
|---|
FileContentManager() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
checkAndBuildContentPath(java.lang.String contentFolderPath) |
protected java.io.File |
getContentFolder() |
protected org.apache.commons.logging.Log |
getLogger() |
java.io.File |
readContent(java.net.URI destUri)
Abstract method to implement: the class is expected to save the content and return the URI of the save content.
|
java.net.URI |
writeContent(java.io.InputStream content)
Abstract method to implement : the implementation is expected to save the content in common content repository of the platform and return the URI of the
save content.
|
java.net.URI |
writeExposedContent(java.io.InputStream content)
Abstract method to implement : the implementation is expected to save the content in a repository which enables end-user to access the content and return
the final URI of the save content (used for client).
|
public static final java.lang.String FILE_CONTENT_MANAGER_PROPERTIES_FILE
public static final java.lang.String NETWORK_SCHEMES
public static final java.lang.String FILE_SCHEME
public static final java.lang.String FOLDER_CONTENT_PATH_PROPERTY_NAME
public static final java.lang.String FOLDER_CONTENT_DEFAULT_PATH
public static final java.lang.String PREFIX
public static final java.lang.String SUFFIX
public java.net.URI writeContent(java.io.InputStream content)
throws org.ow2.weblab.core.extended.exception.WebLabCheckedException
ContentWriterwriteContent in interface ContentWritercontent - an inputStream leading to the raw bytes of the contentorg.ow2.weblab.core.extended.exception.WebLabCheckedExceptionpublic java.net.URI writeExposedContent(java.io.InputStream content)
throws org.ow2.weblab.core.extended.exception.WebLabCheckedException
ContentWriterwriteExposedContent in interface ContentWritercontent - an inputStream leading to the raw bytes of the contentorg.ow2.weblab.core.extended.exception.WebLabCheckedExceptionpublic java.io.File readContent(java.net.URI destUri)
throws org.ow2.weblab.core.extended.exception.WebLabCheckedException
ContentReaderreadContent in interface ContentReaderdestUri - the URI of the content to readorg.ow2.weblab.core.extended.exception.WebLabCheckedExceptionprotected void checkAndBuildContentPath(java.lang.String contentFolderPath)
throws org.ow2.weblab.core.extended.exception.WebLabUncheckedException
org.ow2.weblab.core.extended.exception.WebLabUncheckedExceptionprotected java.io.File getContentFolder()
protected org.apache.commons.logging.Log getLogger()
Copyright © 2004-2012. All Rights Reserved.