I'm trying to upload image to Adobe Creative Cloud using method create:folder:dataPath:contentType:progressBlock:successBlock:cancellationBlock:errorBlock
of AdobeAssetFile. File upload succesfully, but I can't track upload progress with progressBlock
. This block just don't invocated.
- (void)sendImageWithURL:(NSURL *)imageURL {
NSString *imageName = [imageURL lastPathComponent];
[AdobeAssetFile create:imageName
folder:[AdobeAssetFolder root]
dataPath:imageURL
contentType:[AdobeAssetMimeTypes mimeTypeForExtension:@"jpg"]
collisionPolicy:AdobeAssetFileCollisionPolicyAppendUniqueNumber
progressBlock:^(double fractionCompleted) {
NSLog(@"Progress: %f", fractionCompleted);
}
successBlock:^(AdobeAssetFile *file) {
NSLog(@"Operation is complete");
}
cancellationBlock:^{
NSLog(@"Operation is canceled");
}
errorBlock:^(NSError *error){
NSLog(@"Error is occur: %@", error.localizedDescription);
}
];
}
What's wrong with this code? And why progressBlock
not invocated?
I'm using Adobe Creative SDK v0.13.2139.