|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectfr.paris.lutece.plugins.form.service.upload.FormAsynchronousUploadHandler
public class FormAsynchronousUploadHandler
FormAsynchronousUploadHandler.
#getFileItem(String, String),
#removeFileItem(String, String)| Field Summary | |
|---|---|
static Map<String,Map<String,List<org.apache.commons.fileupload.FileItem>>> |
_mapAsynchronousUpload
contains uploaded file items |
static String |
UPLOAD_CHECKBOX_PREFIX
|
static String |
UPLOAD_DELETE_PREFIX
|
static String |
UPLOAD_SUBMIT_PREFIX
|
| Constructor Summary | |
|---|---|
FormAsynchronousUploadHandler()
|
|
| Method Summary | |
|---|---|
void |
addFileItemToUploadedFile(org.apache.commons.fileupload.FileItem fileItem,
String strIdEntry,
javax.servlet.http.HttpSession session)
Add file item to the list of uploaded files |
String |
buildFieldName(String strIdEntry)
Build the field name from a given id entry i.e. : form_1 |
void |
doUploadAction(javax.servlet.http.HttpServletRequest request,
String strUploadAction)
Performs an upload action. |
List<org.apache.commons.fileupload.FileItem> |
getFileItems(String strIdEntry,
String strSessionId)
Gets the fileItem for the entry and the given session. |
static FormAsynchronousUploadHandler |
getHandler()
Get the handler |
String |
getUploadAction(javax.servlet.http.HttpServletRequest request)
Checks the request parameters to see if an upload submit has been called. |
boolean |
isInvoked(javax.servlet.http.HttpServletRequest request)
|
void |
process(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
net.sf.json.JSONObject mainObject,
List<org.apache.commons.fileupload.FileItem> listFileItemsToUpload)
|
void |
removeFileItem(String strIdEntry,
String strSessionId,
int nIndex)
Remove file Item |
void |
removeSessionFiles(String strSessionId)
Removes all files associated to the session |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static Map<String,Map<String,List<org.apache.commons.fileupload.FileItem>>> _mapAsynchronousUpload
public static final String UPLOAD_SUBMIT_PREFIX
public static final String UPLOAD_DELETE_PREFIX
public static final String UPLOAD_CHECKBOX_PREFIX
| Constructor Detail |
|---|
public FormAsynchronousUploadHandler()
| Method Detail |
|---|
public static FormAsynchronousUploadHandler getHandler()
public boolean isInvoked(javax.servlet.http.HttpServletRequest request)
isInvoked in interface fr.paris.lutece.portal.web.upload.IAsynchronousUploadHandler
public void process(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
net.sf.json.JSONObject mainObject,
List<org.apache.commons.fileupload.FileItem> listFileItemsToUpload)
process in interface fr.paris.lutece.portal.web.upload.IAsynchronousUploadHandler
public List<org.apache.commons.fileupload.FileItem> getFileItems(String strIdEntry,
String strSessionId)
strIdEntry - the entrystrSessionId - the session id
null otherwise.
public void removeFileItem(String strIdEntry,
String strSessionId,
int nIndex)
strIdEntry - the id entrystrSessionId - the session idnIndex - the indexpublic void removeSessionFiles(String strSessionId)
strSessionId - the session idpublic String getUploadAction(javax.servlet.http.HttpServletRequest request)
request - the HTTP request
public void doUploadAction(javax.servlet.http.HttpServletRequest request,
String strUploadAction)
request - the HTTP requeststrUploadAction - the name of the upload action
public void addFileItemToUploadedFile(org.apache.commons.fileupload.FileItem fileItem,
String strIdEntry,
javax.servlet.http.HttpSession session)
fileItem - the file itemstrIdEntry - the id entrysession - the sessionpublic String buildFieldName(String strIdEntry)
strIdEntry - the id entry
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||