public class StreamACP extends StreamContent
The default implementation generates an ACP file containing the provided NodeRefs and all their respective children.
Modifier and Type | Field and Description |
---|---|
protected ExporterService |
exporterService |
protected static String |
MULTIPART_FORMDATA |
protected static String |
PARAM_NODE_REFS |
protected static String |
TEMP_FILE_PREFIX |
protected static String |
ZIP_EXTENSION |
delegate, mimetypeService, nodeService, permissionService, repository
Constructor and Description |
---|
StreamACP() |
Modifier and Type | Method and Description |
---|---|
protected File |
createACP(ExporterCrawlerParameters params,
String extension,
boolean keepFolderStructure)
Returns an ACP file containing the nodes represented by the given list of NodeRefs.
|
void |
execute(org.springframework.extensions.webscripts.WebScriptRequest req,
org.springframework.extensions.webscripts.WebScriptResponse res) |
protected org.alfresco.service.cmr.repository.NodeRef[] |
getNodeRefs(org.json.JSONObject json)
Attempts to retrieve and convert a JSON array of
NodeRefs from the given JSON object.
|
protected org.alfresco.service.cmr.repository.NodeRef[] |
getNodeRefs(String nodeRefsParam)
Converts the given comma delimited string of NodeRefs to an array
of NodeRefs.
|
void |
setExporterService(ExporterService exporterService)
Sets the ExporterService to use
|
createObjectReferenceFromUrl, executeImpl, executeImpl, executeImpl, renderFormatTemplate, setAttachment, setDelegate, setMimetypeService, setNodeService, setPermissionService, setRepository, streamContent, streamContent, streamContent, streamContentImpl
addModuleBundleToCache, checkModuleBundleCache, createArgs, createArgsM, createHeaders, createHeadersM, createScriptParameters, createStatusException, createTemplateParameters, executeScript, getContainer, getDescription, getExecuteScript, getResources, getStatusTemplate, init, renderString, renderString, renderTemplate, sendStatus, setURLModelFactory, toString
protected static final String TEMP_FILE_PREFIX
protected static final String MULTIPART_FORMDATA
protected static final String ZIP_EXTENSION
protected static final String PARAM_NODE_REFS
protected ExporterService exporterService
public void setExporterService(ExporterService exporterService)
exporterService
- The ExporterServicepublic void execute(org.springframework.extensions.webscripts.WebScriptRequest req, org.springframework.extensions.webscripts.WebScriptResponse res) throws IOException
execute
in interface org.springframework.extensions.webscripts.WebScript
execute
in class StreamContent
IOException
WebScript.execute(org.springframework.extensions.webscripts.WebScriptRequest, org.springframework.extensions.webscripts.WebScriptResponse)
protected org.alfresco.service.cmr.repository.NodeRef[] getNodeRefs(String nodeRefsParam)
nodeRefsParam
- Comma delimited string of NodeRefsprotected org.alfresco.service.cmr.repository.NodeRef[] getNodeRefs(org.json.JSONObject json) throws org.json.JSONException
json
- JSONObjectorg.json.JSONException
protected File createACP(ExporterCrawlerParameters params, String extension, boolean keepFolderStructure)
params
- The parameters for the ACP exporterextension
- The file extenstion to use for the ACP filekeepFolderStructure
- Determines whether the folder structure is maintained for
the content inside the ACP fileCopyright © 2005–2017 Alfresco Software. All rights reserved.