Package org.zkoss.zats.mimic.operation
Interface UploadAgent
- All Superinterfaces:
Agent,OperationAgent
The agent for files uploading operation.
Supported components with upload property such as Button, Menuitem and Toolbarbutton.
DesktopAgent can be UploadAgent for specific case such as uploading by Fileupload.get().
Notice that you should use the same instance in one uploading iteration.
- Since:
- 1.1.0
- Author:
- pao
-
Method Summary
Methods inherited from interface org.zkoss.zats.mimic.Agent
getClient, getDelegatee
-
Method Details
-
upload
Upload a file from input stream to ZK web application. The input stream won't be closed, it should be closed manually.- Parameters:
fileName- specify name for uploading file, should not be null.content- content of uploaded file, should not be null.contentType- specify type of content. If null, indicate it is binary form.- See Also:
-
upload
Upload a file to ZK web application.- Parameters:
file- file for uploading, should not be null.contentType- specify type of content. If null, indicate it is binary form.- See Also:
-
finish
void finish()Invoke this method when uploading finished.
-