public class ReportingDownloadOperation extends Object
| Constructor and Description |
|---|
ReportingDownloadOperation(String requestId,
AuthorizationData authorizationData) |
ReportingDownloadOperation(String requestId,
AuthorizationData authorizationData,
ApiEnvironment apiEnvironment) |
| Modifier and Type | Method and Description |
|---|---|
Future<File> |
downloadResultFileAsync(File localResultDirectoryName,
String localResultFileName,
boolean decompress,
AsyncCallback<File> callback)
Downloads and optionally decompress the result file from the reporting download operation.
|
Future<File> |
downloadResultFileAsync(File localResultDirectoryName,
String localResultFileName,
boolean decompress,
boolean overwrite,
AsyncCallback<File> callback)
Downloads and optionally decompress the result file from the bulk operation, allows to overwrite the local result file.
|
AuthorizationData |
getAuthorizationData() |
int |
getDownloadHttpTimeoutInMilliseconds()
Gets the timeout of HttpClient download operation.
|
ReportingOperationStatus |
getFinalStatus() |
HttpFileService |
getHttpFileService() |
String |
getRequestId() |
ServiceClient<IReportingService> |
getServiceClient() |
Future<ReportingOperationStatus> |
getStatusAsync(AsyncCallback<ReportingOperationStatus> callback)
Gets the status of the reporting download operation.
|
int |
getStatusPollIntervalInMilliseconds()
Gets the time interval in milliseconds between two status polling attempts.
|
ReportingStatusProvider |
getStatusProvider() |
String |
getTrackingId() |
ZipExtractor |
getZipExtractor() |
void |
setDownloadHttpTimeoutInMilliseconds(int downloadHttpTimeoutInMilliseconds)
Sets the timeout of HttpClient download operation.
|
void |
setFinalStatus(ReportingOperationStatus finalStatus) |
void |
setHttpFileService(HttpFileService httpFileService) |
void |
setRequestId(String requestId) |
void |
setServiceClient(ServiceClient<IReportingService> serviceClient) |
void |
setStatusPollIntervalInMilliseconds(int statusPollIntervalInMilliseconds)
Sets the time interval in milliseconds between two status polling attempts.
|
void |
setStatusProvider(ReportingStatusProvider statusProvider) |
void |
setTrackingId(String trackingId) |
void |
setZipExtractor(ZipExtractor zipExtractor) |
Future<ReportingOperationStatus> |
trackAsync(AsyncCallback<ReportingOperationStatus> callback)
Runs asynchronously until the reporting service has finished processing the reporting download operation.
|
public ReportingDownloadOperation(String requestId, AuthorizationData authorizationData)
requestId - authorizationData - public ReportingDownloadOperation(String requestId, AuthorizationData authorizationData, ApiEnvironment apiEnvironment)
public Future<ReportingOperationStatus> trackAsync(AsyncCallback<ReportingOperationStatus> callback)
callback - A handler that will be called with the ReportingDownloadOperation when it has completedpublic Future<ReportingOperationStatus> getStatusAsync(AsyncCallback<ReportingOperationStatus> callback)
ReportingOperationStatus object pointing to the current status of the reporting download operation in Futurepublic Future<File> downloadResultFileAsync(File localResultDirectoryName, String localResultFileName, boolean decompress, AsyncCallback<File> callback) throws IOException, URISyntaxException
localResultDirectoryName - the directory to place the result file inlocalResultFileName - the name to use for final result filedecompress - indicates whether the result file should be unzippedcallback - AsyncCallback object with FileFile object pointing to the result file wrapped in FutureIOExceptionURISyntaxExceptionpublic Future<File> downloadResultFileAsync(File localResultDirectoryName, String localResultFileName, boolean decompress, boolean overwrite, AsyncCallback<File> callback) throws IOException, URISyntaxException
localResultDirectoryName - the directory to place the result file inlocalResultFileName - the name to use for final result filedecompress - indicates whether the result file should be unzippedoverwrite - indicates whether can overwrite if target file existscallback - AsyncCallback object with FileFile object pointing to the result file wrapped in FutureIOExceptionURISyntaxExceptionpublic AuthorizationData getAuthorizationData()
public String getRequestId()
public void setRequestId(String requestId)
requestId - the requestId to setpublic String getTrackingId()
public void setTrackingId(String trackingId)
trackingId - the trackingId to setpublic ReportingStatusProvider getStatusProvider()
public void setStatusProvider(ReportingStatusProvider statusProvider)
statusProvider - the statusProvider to setpublic HttpFileService getHttpFileService()
public void setHttpFileService(HttpFileService httpFileService)
httpFileService - the httpFileService to setpublic ZipExtractor getZipExtractor()
public void setZipExtractor(ZipExtractor zipExtractor)
zipExtractor - the zipExtractor to setpublic ServiceClient<IReportingService> getServiceClient()
public void setServiceClient(ServiceClient<IReportingService> serviceClient)
serviceClient - the serviceClient to setpublic ReportingOperationStatus getFinalStatus()
public void setFinalStatus(ReportingOperationStatus finalStatus)
finalStatus - the finalStatus to setpublic int getStatusPollIntervalInMilliseconds()
public void setStatusPollIntervalInMilliseconds(int statusPollIntervalInMilliseconds)
public int getDownloadHttpTimeoutInMilliseconds()
public void setDownloadHttpTimeoutInMilliseconds(int downloadHttpTimeoutInMilliseconds)
Copyright © 2024. All rights reserved.