Package org.pentaho.platform.web.servlet
Interface IUploadFileServletPlugin
-
public interface IUploadFileServletPluginAllows a platform plugin to provide it's own file uploading capability which is not currently supported inIContentGenerator.- Author:
- aphillips
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description StringgetFileExtension()The file extension to append to the randomly generated filename resulting from the file upload.longgetMaxFileSize()The maximum permitted upload file size in byteslonggetMaxFolderSize()The maximum number of files allowed in the target folder.StringgetTargetFolder()A path where the uploaded files will be saved, relative to the solution path.voidonSuccess(String pathToFile, javax.servlet.http.HttpServletResponse response)A callback invoked upon successful file upload.
-
-
-
Method Detail
-
getTargetFolder
String getTargetFolder()
A path where the uploaded files will be saved, relative to the solution path.- Returns:
- solution-relative path where files will be saved.
-
getMaxFileSize
long getMaxFileSize()
The maximum permitted upload file size in bytes- Returns:
- max files size in bytes
-
getMaxFolderSize
long getMaxFolderSize()
The maximum number of files allowed in the target folder.- Returns:
- max number of files in target folder
-
getFileExtension
String getFileExtension()
The file extension to append to the randomly generated filename resulting from the file upload.- Returns:
- the file extension (must explicitly include the '.' character)
-
onSuccess
void onSuccess(String pathToFile, javax.servlet.http.HttpServletResponse response)
A callback invoked upon successful file upload. TheUploadFileServletcan do whatever it needs to with the repsonse which will be the actual servlet response.- Parameters:
pathToFile- the absolute path to the file successfully uploadedresponse- the servlet response when the file upload succeedes
-
-