|
|||||||||
| Home >> All >> org >> apache >> turbine >> services >> [ upload overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
org.apache.turbine.services.upload
Class TurbineUploadService

java.lang.Objectorg.apache.turbine.services.BaseInitable
org.apache.turbine.services.BaseService
org.apache.turbine.services.TurbineBaseService
org.apache.turbine.services.upload.TurbineUploadService
- All Implemented Interfaces:
- org.apache.turbine.services.Initable, org.apache.turbine.services.Service, UploadService
- public class TurbineUploadService
- extends org.apache.turbine.services.TurbineBaseService
- implements UploadService
- extends org.apache.turbine.services.TurbineBaseService
This class is an implementation of UploadService.
Files will be stored in temporary disk storage on in memory, depending on request size, and will be available from the org.apache.turbine.util.parser.ParameterParser as org.apache.commons.fileupload.FileItems.
This implementation of UploadService handles multiple
files per single html widget, sent using multipar/mixed encoding
type, as specified by RFC 1867. Use ParameterParser.getFileItems(String)>ParameterParser.getFileItems(String) 55 to
acquire an array of org.apache.commons.fileupload.FileItems associated with given
html widget.
- Version:
- $Id: TurbineUploadService.java 279820 2005-09-09 17:05:54Z henning $
| Field Summary | |
private boolean |
automatic
Auto Upload yes? |
protected org.apache.commons.fileupload.DiskFileUpload |
fileUpload
A File Upload object for the actual uploading |
private static org.apache.commons.logging.Log |
log
Logging |
| Fields inherited from class org.apache.turbine.services.BaseService |
configuration, name, serviceBroker |
| Fields inherited from class org.apache.turbine.services.BaseInitable |
initableBroker, isInitialized |
| Fields inherited from interface org.apache.turbine.services.upload.UploadService |
AUTOMATIC_DEFAULT, AUTOMATIC_KEY, CONTENT_DISPOSITION, CONTENT_TYPE, FORM_DATA, MIXED, MULTIPART, MULTIPART_FORM_DATA, MULTIPART_MIXED, REPOSITORY_DEFAULT, REPOSITORY_KEY, REPOSITORY_PARAMETER, SERVICE_NAME, SIZE_MAX_DEFAULT, SIZE_MAX_KEY, SIZE_THRESHOLD_DEFAULT, SIZE_THRESHOLD_KEY |
| Constructor Summary | |
TurbineUploadService()
|
|
| Method Summary | |
boolean |
getAutomatic()
Retrieves the value of the 'automatic' property of UploadService. |
java.lang.String |
getRepository()
Retrieves the value of the repository property of
UploadService. |
long |
getSizeMax()
Retrieves the value of size.max property of the
UploadService. |
int |
getSizeThreshold()
Retrieves the value of size.threshold property of
UploadService. |
void |
init()
Initializes the service. |
void |
parseRequest(javax.servlet.http.HttpServletRequest req,
org.apache.turbine.util.parser.ParameterParser params,
java.lang.String path)
Processes an RFC 1867 compliant multipart/form-data stream. |
| Methods inherited from class org.apache.turbine.services.TurbineBaseService |
init, init, init, shutdown |
| Methods inherited from class org.apache.turbine.services.BaseService |
getConfiguration, getName, getProperties, getServiceBroker, setName, setServiceBroker |
| Methods inherited from class org.apache.turbine.services.BaseInitable |
getInit, getInitableBroker, setInit, setInitableBroker |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.apache.turbine.services.Service |
getConfiguration, getName, getProperties, setName, setServiceBroker |
| Methods inherited from interface org.apache.turbine.services.Initable |
getInit, init, setInitableBroker, shutdown |
| Field Detail |
log
private static org.apache.commons.logging.Log log
- Logging
fileUpload
protected org.apache.commons.fileupload.DiskFileUpload fileUpload
- A File Upload object for the actual uploading
automatic
private boolean automatic
- Auto Upload yes?
| Constructor Detail |
TurbineUploadService
public TurbineUploadService()
| Method Detail |
init
public void init()
throws org.apache.turbine.services.InitializationException
- Initializes the service.
This method processes the repository path, to make it relative to the
web application root, if neccessary
- Specified by:
initin interfaceorg.apache.turbine.services.Initable
getSizeMax
public long getSizeMax()
Retrieves the value of
size.maxproperty of the UploadService.- Specified by:
getSizeMaxin interfaceUploadService
getSizeThreshold
public int getSizeThreshold()
Retrieves the value of
size.thresholdproperty of UploadService.- Specified by:
getSizeThresholdin interfaceUploadService
getAutomatic
public boolean getAutomatic()
- Retrieves the value of the 'automatic' property of UploadService. This reports whether the Parameter parser
should allow "automatic" uploads if it is submitted to
Turbine.
- Specified by:
getAutomaticin interfaceUploadService
getRepository
public java.lang.String getRepository()
Retrieves the value of the
repositoryproperty of UploadService.- Specified by:
getRepositoryin interfaceUploadService
parseRequest
public void parseRequest(javax.servlet.http.HttpServletRequest req, org.apache.turbine.util.parser.ParameterParser params, java.lang.String path) throws org.apache.turbine.util.TurbineException
Processes an RFC 1867 compliant
multipart/form-datastream.- Specified by:
parseRequestin interfaceUploadService
|
|||||||||
| Home >> All >> org >> apache >> turbine >> services >> [ upload overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC