use of com.amplifyframework.storage.s3.request.AWSS3StorageGetPresignedUrlRequest in project amplify-android by aws-amplify.
the class AWSS3StoragePlugin method getUrl.
@NonNull
@Override
public StorageGetUrlOperation<?> getUrl(@NonNull String key, @NonNull StorageGetUrlOptions options, @NonNull Consumer<StorageGetUrlResult> onSuccess, @NonNull Consumer<StorageException> onError) {
AWSS3StorageGetPresignedUrlRequest request = new AWSS3StorageGetPresignedUrlRequest(key, options.getAccessLevel() != null ? options.getAccessLevel() : defaultAccessLevel, options.getTargetIdentityId(), options.getExpires() != 0 ? options.getExpires() : defaultUrlExpiration);
AWSS3StorageGetPresignedUrlOperation operation = new AWSS3StorageGetPresignedUrlOperation(storageService, executorService, cognitoAuthProvider, request, awsS3StoragePluginConfiguration, onSuccess, onError);
operation.start();
return operation;
}
Aggregations