Product Overview
Feature Description
Product Strengths
Use Cases
Basic Concept
API | Operation Description |
Batch recover files in the recycle bin |
QCloudSMHBatchRestoreRecycleObjectReqeust *req = [QCloudSMHBatchRestoreRecycleObjectReqeust new];req.priority = self.priority;req.libraryId = self.libraryId;req.spaceId = self.spaceId;req.recycledItemIds = self.batchInfos;[req setFinishBlock:^(QCloudSMHBatchResult *result, NSError * _Nullable error) {//if it is a sync task, obtain the task status from the http status codeQCloudSMHBatchTaskStatus status = QCloudSMHBatchTaskStatusTypeFromStatus([result __originHTTPURLResponse__].statusCode);result.status = status;if(status != QCloudSMHBatchTaskStatusWating || error){// End when task status is not wait or there is an errorif(self.finishBlock){self.finishBlock(result, error);}}else{// Use the returned taskid to poll task statusresult.taskId;}}];[[QCloudSMHService defaultSMHService]batchRestoreRecycleObject:req];
QCloudGetTaskStatusRequest *req = [QCloudGetTaskStatusRequest new];req.spaceId = @"spaceId";req.libraryId = @"libraryId";// taskId returned from the previous stepreq.taskIdList = @[taskId];[req setFinishBlock:^(NSArray * _Nonnull result, NSError * _Nonnull error) {}];[[QCloudSMHService defaultSMHService] getTaskStatus:req];
QCloudSMHRestoreObjectRequest *req = [QCloudSMHRestoreObjectRequest new];req.spaceId = @"spaceId";req.libraryId = @"libraryId";req.batchInfos = @[@"1"];[req setFinishBlock:^(QCloudSMHBatchResult *result, NSError *_Nullable error) {}];[[QCloudSMHService defaultSMHService] restoreObject:req];
Apakah halaman ini membantu?
Anda juga dapat Menghubungi Penjualan atau Mengirimkan Tiket untuk meminta bantuan.
masukan