Class ProgressReportingRequestBody.Builder
java.lang.Object
com.amilesend.client.connection.file.ProgressReportingRequestBody.Builder
- Enclosing class:
- ProgressReportingRequestBody
The builder used to construct new 
ProgressReportingRequestBody instances for uploads.- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionbuild()Builds a newRequestBodythat tracks the transfer progress for multipart form-data transfer.callback(TransferProgressCallback callback) The callback listener.contentType(String contentType) The content type.destination(String destination) The destination descriptor (i.e., the name of the service).The file to upload.
- 
Constructor Details- 
Builderpublic Builder()
 
- 
- 
Method Details- 
fileThe file to upload.- Parameters:
- file- the path of the file to upload
- Returns:
- the builder
 
- 
contentTypeThe content type. The default istext/csv.- Parameters:
- contentType- the content type
- Returns:
- the builder
 
- 
destinationThe destination descriptor (i.e., the name of the service).- Parameters:
- destination- the destination
- Returns:
- the builder
 
- 
callbackThe callback listener. Default is aLogProgressCallback.- Parameters:
- callback- the listener
- Returns:
- the builder
 
- 
buildBuilds a newRequestBodythat tracks the transfer progress for multipart form-data transfer.- Returns:
- the request body
- Throws:
- IOException- if an error occurred while accessing the file to read
 
 
-