public class JSPUploadStep extends JSPStep
This JSPStep class works with the SubmissionController servlet for the JSP-UI
The following methods are called in this order:
SubmissionController,
JSPStep,
UploadStep| Modifier and Type | Field and Description |
|---|---|
protected static java.lang.String |
UPLOAD_ERROR_JSP
JSP to show any upload errors *
|
protected static java.lang.String |
VIRUS_CHECKER_ERROR_JSP
JSP to show any upload errors *
|
protected static java.lang.String |
VIRUS_ERROR_JSP
JSP to show any upload errors *
|
| Constructor and Description |
|---|
JSPUploadStep() |
| Modifier and Type | Method and Description |
|---|---|
void |
doPostProcessing(Context context,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
SubmissionInfo subInfo,
int status)
Do any post-processing after the step's backend processing occurred (in
the doProcessing() method).
|
void |
doPreProcessing(Context context,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
SubmissionInfo subInfo)
Do any pre-processing to determine which JSP (if any) is used to generate
the UI for this step.
|
java.lang.String |
getReviewJSP(Context context,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
SubmissionInfo subInfo)
Return the URL path (e.g.
|
protected void |
showChooseFile(Context context,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
SubmissionInfo subInfo)
Show the page which allows the user to choose another file to upload
|
protected void |
showFileDescription(Context context,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
SubmissionInfo subInfo)
Show the page which allows the user to edit the description of already
uploaded files
|
protected void |
showGetFileFormat(Context context,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
SubmissionInfo subInfo)
Show the page which allows the user to change the format of the file that
was just uploaded
|
protected void |
showUploadFileList(Context context,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
SubmissionInfo subInfo,
boolean justUploaded,
boolean showChecksums)
Show the page which lists all the currently uploaded files
|
protected void |
showUploadPage(Context context,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
SubmissionInfo subInfo,
boolean justUploaded)
Display the appropriate upload page in the file upload sequence.
|
protected static final java.lang.String UPLOAD_ERROR_JSP
protected static final java.lang.String VIRUS_CHECKER_ERROR_JSP
protected static final java.lang.String VIRUS_ERROR_JSP
public void doPreProcessing(Context context, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, SubmissionInfo subInfo) throws javax.servlet.ServletException, java.io.IOException, java.sql.SQLException, AuthorizeException
If this step requires user interaction, then this method must call the JSP to display, using the "showJSP()" method of the JSPStepManager class.
If this step doesn't require user interaction OR you are solely using Manakin for your user interface, then this method may be left EMPTY, since all step processing should occur in the doProcessing() method.
doPreProcessing in class JSPStepcontext - current DSpace contextrequest - current servlet request objectresponse - current servlet response objectsubInfo - submission info objectjavax.servlet.ServletExceptionjava.io.IOExceptionjava.sql.SQLExceptionAuthorizeExceptionpublic void doPostProcessing(Context context, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, SubmissionInfo subInfo, int status) throws javax.servlet.ServletException, java.io.IOException, java.sql.SQLException, AuthorizeException
It is this method's job to determine whether processing completed successfully, or display another JSP informing the users of any potential problems/errors.
If this step doesn't require user interaction OR you are solely using Manakin for your user interface, then this method may be left EMPTY, since all step processing should occur in the doProcessing() method.
doPostProcessing in class JSPStepcontext - current DSpace contextrequest - current servlet request objectresponse - current servlet response objectsubInfo - submission info objectstatus - any status/errors reported by doProcessing() methodjavax.servlet.ServletExceptionjava.io.IOExceptionjava.sql.SQLExceptionAuthorizeExceptionprotected void showUploadPage(Context context, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, SubmissionInfo subInfo, boolean justUploaded) throws java.sql.SQLException, javax.servlet.ServletException, java.io.IOException
context - the DSpace context objectrequest - the request objectresponse - the response objectsubInfo - the SubmissionInfo objectjustUploaded - true, if the user just finished uploading a filejava.sql.SQLExceptionjavax.servlet.ServletExceptionjava.io.IOExceptionprotected void showChooseFile(Context context, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, SubmissionInfo subInfo) throws java.sql.SQLException, javax.servlet.ServletException, java.io.IOException
context - current DSpace contextrequest - the request objectresponse - the response objectsubInfo - the SubmissionInfo objectjava.sql.SQLExceptionjavax.servlet.ServletExceptionjava.io.IOExceptionprotected void showUploadFileList(Context context, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, SubmissionInfo subInfo, boolean justUploaded, boolean showChecksums) throws java.sql.SQLException, javax.servlet.ServletException, java.io.IOException
context - current DSpace contextrequest - the request objectresponse - the response objectsubInfo - the SubmissionInfo objectjustUploaded - pass in true if the user just successfully uploaded a fileshowChecksums - pass in true if checksums should be displayedjava.sql.SQLExceptionjavax.servlet.ServletExceptionjava.io.IOExceptionprotected void showGetFileFormat(Context context, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, SubmissionInfo subInfo) throws java.sql.SQLException, javax.servlet.ServletException, java.io.IOException
context - context objectrequest - the request objectresponse - the response objectsubInfo - the SubmissionInfo objectjava.sql.SQLExceptionjavax.servlet.ServletExceptionjava.io.IOExceptionprotected void showFileDescription(Context context, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, SubmissionInfo subInfo) throws java.sql.SQLException, javax.servlet.ServletException, java.io.IOException
context - context objectrequest - the request objectresponse - the response objectsubInfo - the SubmissionInfo objectjava.sql.SQLExceptionjavax.servlet.ServletExceptionjava.io.IOExceptionpublic java.lang.String getReviewJSP(Context context, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, SubmissionInfo subInfo)
This Review JSP is loaded by the 'Verify' Step, in order to dynamically generate a submission verification page consisting of the information gathered in all the enabled submission steps.
getReviewJSP in class JSPStepcontext - current DSpace contextrequest - current servlet request objectresponse - current servlet response objectsubInfo - submission info objectCopyright © 2018 DuraSpace. All Rights Reserved.