@Named @ConversationScoped public class FileUploadController extends Object implements Serializable
AjaxFileUploadServlet.doPost,
Serialized Form| Constructor and Description |
|---|
FileUploadController() |
| Modifier and Type | Method and Description |
|---|---|
void |
addAttachedFile(org.imixs.workflow.FileData filedata)
This method is called by the AjaxFileUpload Servlet.
|
List<org.imixs.workflow.FileData> |
getAttachedFiles()
returns the list of currently new attached files.
|
String |
getCID()
Returns the current conversation id.
|
String |
getFileSize(String aFilename)
get the file size for a given filename in human readable format
|
List<org.imixs.workflow.FileData> |
getPersistedFiles()
returns the list of already persisted files.
|
org.imixs.workflow.ItemCollection |
getWorkitem()
Setter method to get an instance of the current workitem the FileData should
be stored.
|
void |
onWorkflowEvent(WorkflowEvent workflowEvent)
WorkflowEvent listener
If a new WorkItem was created the file upload will be reset.
|
void |
removeAttachedFile(String aFilename)
Removes a attached file object from the tmp list of uploaded files.
|
void |
removePersistedFile(String aFilename)
Removes a file object from a given workitem.
|
static double |
round(double value)
helper method to round for 2 digits.
|
void |
setWorkitem(org.imixs.workflow.ItemCollection workitem)
This method set the current workitem and starts a new conversation.
|
public org.imixs.workflow.ItemCollection getWorkitem()
public void setWorkitem(org.imixs.workflow.ItemCollection workitem)
workitem - public String getCID()
public void onWorkflowEvent(@Observes
WorkflowEvent workflowEvent)
If a new WorkItem was created the file upload will be reset.
workflowEvent - public void addAttachedFile(org.imixs.workflow.FileData filedata)
document - aFilename - public void removeAttachedFile(String aFilename)
sFilename - - filename to be removedpublic void removePersistedFile(String aFilename)
sFilename - - filename to be removedpublic List<org.imixs.workflow.FileData> getAttachedFiles()
public List<org.imixs.workflow.FileData> getPersistedFiles()
public String getFileSize(String aFilename)
sFilename - - filename to be removedpublic static double round(double value)
value - places - Copyright © 2006–2020 Imixs Software Solutions GmbH. All rights reserved.