public class UploadContentServlet extends BaseServlet
The URL to the servlet should be generated thus:
/alfresco/upload/workspace/SpacesStore/0000-0000-0000-0000/myfile.pdfor
/alfresco/upload/myfile.pdf
If the store and node id are specified in the URL then the content provided will be streamed onto the node using an updating writer, updating the content property value accordingly.
If only the file name is specified the content will be streamed into the content store and the content data will be returned in the reposonse. This can then be used to update the value of a content property manually. Any used content will be cleared up in the usual manner.
By default, the download assumes that the content is on the
content property.
To set the content of a specific model property, use a 'property' arg, providing the qualified name of the property.
Like most Alfresco servlets, the URL may be followed by a valid 'ticket' argument for authentication: ?ticket=1234567890
Guest access is currently disabled for this servlet.
BaseServlet.PathRefInfo| Modifier and Type | Field and Description |
|---|---|
protected static java.lang.String |
ARG_ENCODING |
protected static java.lang.String |
ARG_MIMETYPE |
protected static java.lang.String |
ARG_PROPERTY
Argument properties
|
protected static java.lang.String |
MIMETYPE_OCTET_STREAM
Default mime type
|
FACES_SERVLET, KEY_ROOT_PATH, KEY_STORE| Constructor and Description |
|---|
UploadContentServlet() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
doPut(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse res) |
checkAccess, getServiceRegistry, redirectToLoginPage, resolveNamePath, resolveWebDAVPath, resolveWebDAVPath, resolveWebDAVPath, resolveWebDAVPath, servletAuthenticate, servletAuthenticate, setNoCacheHeaders, validRedirectJSPdoDelete, doGet, doHead, doOptions, doPost, doTrace, getLastModified, service, serviceprotected static final java.lang.String MIMETYPE_OCTET_STREAM
protected static final java.lang.String ARG_PROPERTY
protected static final java.lang.String ARG_MIMETYPE
protected static final java.lang.String ARG_ENCODING
protected void doPut(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse res)
throws javax.servlet.ServletException,
java.io.IOException
doPut in class javax.servlet.http.HttpServletjavax.servlet.ServletExceptionjava.io.IOExceptionHttpServlet.doPut(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)Copyright © 2005 - 2010 Alfresco Software, Inc. All Rights Reserved.