diff --git a/CHANGELOG.md b/CHANGELOG.md index baa3d0e..5cc96a3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,22 +1,21 @@ -# 6.4.0 - -1、修改getBucket接口漏洞 +# 6.4.1 +1、支持cos请求使用单临时秘钥。2、新增元数据接口。3、修复一直问题。 -# 6.3.9 +# 6.4.0 +1、修改getBucket接口漏洞 + +# 6.3.9 1、高级上传接口支持callback。 2、优化上传contenttype参数。 3、修改WeakSelf为QCloudWeakSelf; -4、修复 其他已知问题。 - +4、修复 其他已知问题。 + # 6.3.8 - -修复断点下载问题 - +修复断点下载问题 # 6.3.7 - 1.默认https协议。 2、提供httpdns全局开关。 3、修复6.3.5,6.3.6灯塔crash。 diff --git a/Podfile.lock b/Podfile.lock index 7c8a776..1154a35 100644 --- a/Podfile.lock +++ b/Podfile.lock @@ -1,22 +1,22 @@ PODS: - GMOpenSSL (2.2.9) - - QCloudCore (6.3.9): - - QCloudCore/Default (= 6.3.9) - - QCloudCore/Default (6.3.9): - - QCloudTrack/Beacon (= 6.3.9) - - QCloudCOSXML (6.3.9): - - QCloudCOSXML/Default (= 6.3.9) - - QCloudCOSXML/Default (6.3.9): - - QCloudCore (= 6.3.9) - - QCloudQuic (6.3.7): - - QCloudQuic/Default (= 6.3.7) - - QCloudQuic/Default (6.3.7) - - QCloudTrack (6.3.9): - - QCloudTrack/Default (= 6.3.9) - - QCloudTrack/Beacon (6.3.9) - - QCloudTrack/Cls (6.3.9): + - QCloudCore (6.4.1): + - QCloudCore/Default (= 6.4.1) + - QCloudCore/Default (6.4.1): + - QCloudTrack/Beacon (= 6.4.1) + - QCloudCOSXML (6.4.1): + - QCloudCOSXML/Default (= 6.4.1) + - QCloudCOSXML/Default (6.4.1): + - QCloudCore (= 6.4.1) + - QCloudQuic (6.3.9): + - QCloudQuic/Default (= 6.3.9) + - QCloudQuic/Default (6.3.9) + - QCloudTrack (6.4.1): + - QCloudTrack/Default (= 6.4.1) + - QCloudTrack/Beacon (6.4.1) + - QCloudTrack/Cls (6.4.1): - TencentCloudLogProducer - - QCloudTrack/Default (6.3.9) + - QCloudTrack/Default (6.4.1) - TencentCloudLogProducer (1.1.0): - TencentCloudLogProducer/Core (= 1.1.0) - TencentCloudLogProducer/Core (1.1.0): @@ -47,12 +47,12 @@ EXTERNAL SOURCES: SPEC CHECKSUMS: GMOpenSSL: d6d119ff8f00d4e03c2cdf733fb61e98e22da9c7 - QCloudCore: aed46aa9cf2656373682d6aa3b0c3f252f1875f7 - QCloudCOSXML: a8139aaa7db0c74c870a5a36ccccbee89d5cad75 - QCloudQuic: 895ccf08046ecf068a6f965831dd16fc7d531fb4 - QCloudTrack: 00557c28b5b1a2cd4a0cf2c41a34947d8a19d119 + QCloudCore: 6252d05b183f45698550c5445de85826fd89f9a5 + QCloudCOSXML: 48557a25a8803093a80951e65753a68275ff967d + QCloudQuic: 81e2c29fa8122c1d5e8323a90349683e52c8e101 + QCloudTrack: 7458275adda5626dd2dc99367e3993080ab119c8 TencentCloudLogProducer: 4ccf2eb45c432180351564b1447b98d9b23ca37a PODFILE CHECKSUM: 469848875513aa1180afa1e3751e2d873841a154 -COCOAPODS: 1.12.1 +COCOAPODS: 1.15.2 diff --git a/QCloudCOSXML.podspec b/QCloudCOSXML.podspec index df2f7a1..2bd3e9a 100644 --- a/QCloudCOSXML.podspec +++ b/QCloudCOSXML.podspec @@ -2,7 +2,7 @@ Pod::Spec.new do |s| s.name = "QCloudCOSXML" -s.version = "6.4.0" +s.version = "6.4.1" s.summary = "QCloudCOSXML 腾讯云iOS-SDK组件" @@ -20,22 +20,22 @@ s.version = "6.4.0" s.default_subspec = 'Default' s.subspec 'Default' do |default| default.source_files = 'QCloudCOSXML/Classes/**/*','QCloudCOSXML/Classes/QCloudCOSXML/*' - default.dependency "QCloudCore",'6.4.0' + default.dependency "QCloudCore",'6.4.1' end s.subspec 'Slim' do |slim| slim.source_files = 'QCloudCOSXML/Classes/**/*','QCloudCOSXML/Classes/QCloudCOSXML/*' - slim.dependency "QCloudCore/WithoutMTA",'6.4.0' + slim.dependency "QCloudCore/WithoutMTA",'6.4.1' end s.subspec 'Transfer' do |transfer| transfer.source_files = 'QCloudCOSXML/Classes/*','QCloudCOSXML/Classes/Transfer/**/*','QCloudCOSXML/Classes/Base/**/*' - transfer.dependency "QCloudCore/WithoutMTA",'6.4.0' + transfer.dependency "QCloudCore/WithoutMTA",'6.4.1' end s.subspec 'Widget' do |widget| widget.source_files = 'QCloudCOSXML/Classes/*','QCloudCOSXML/Classes/Transfer/**/*','QCloudCOSXML/Classes/Base/**/*' widget.exclude_files = 'QCloudCOSXML/Classes/Base/QCloudLogManager.h','QCloudCOSXML/Classes/Base/QCloudLogManager.m' - widget.dependency "QCloudCore/WithoutMTA",'6.4.0' + widget.dependency "QCloudCore/WithoutMTA",'6.4.1' end end diff --git a/QCloudCOSXML/Classes/Base/QCloudCOSXMLEndPoint.h b/QCloudCOSXML/Classes/Base/QCloudCOSXMLEndPoint.h index 12aeac8..d8daca1 100644 --- a/QCloudCOSXML/Classes/Base/QCloudCOSXMLEndPoint.h +++ b/QCloudCOSXML/Classes/Base/QCloudCOSXMLEndPoint.h @@ -36,6 +36,7 @@ // 是否切换到旧域名 // */ //@property (nonatomic, assign) BOOL enableOldDomain; +- (NSURL *)serverURLWithProductName:(NSString *)productName AppID:(NSString *)appID regionName:(NSString *)regionName; @end diff --git a/QCloudCOSXML/Classes/Base/QCloudCOSXMLEndPoint.m b/QCloudCOSXML/Classes/Base/QCloudCOSXMLEndPoint.m index 7828b2e..4cfa41a 100644 --- a/QCloudCOSXML/Classes/Base/QCloudCOSXMLEndPoint.m +++ b/QCloudCOSXML/Classes/Base/QCloudCOSXMLEndPoint.m @@ -94,6 +94,7 @@ - (NSURL *)serverURLWithBucket:(NSString *)bucket appID:(NSString *)appID region QCloudLogDebug(@"serverURL: %@", serverURL); return serverURL; } + - (void)setIsPrefixURL:(BOOL)isPrefixURL { _isPrefixURL = isPrefixURL; } diff --git a/QCloudCOSXML/Classes/CI/QCloudCOSXMLService+ImageHelper.h b/QCloudCOSXML/Classes/CI/QCloudCOSXMLService+ImageHelper.h index 5408b97..b9b79f9 100644 --- a/QCloudCOSXML/Classes/CI/QCloudCOSXMLService+ImageHelper.h +++ b/QCloudCOSXML/Classes/CI/QCloudCOSXMLService+ImageHelper.h @@ -125,6 +125,17 @@ @class QCloudPostSoundHoundRequest; @class QCloudVocalScoreRequest; @class QCloudCIUploadOperationsRequest; +@class QCloudDescribeFileProcessQueuesRequest; +@class QCloudDescribeFileUnzipJobsRequest; +@class QCloudDescribeFileZipProcessJobsRequest; +@class QCloudCreateFileZipProcessJobsRequest; +@class QCloudCreateHashProcessJobsRequest; +@class QCloudDescribeHashProcessJobsRequest; +@class QCloudPostFileUnzipProcessJobRequest; +@class QCloudPostHashProcessJobsRequest; +@class QCloudUpdateFileProcessQueueRequest; +@class QCloudZipFilePreviewRequest; + NS_ASSUME_NONNULL_BEGIN @interface QCloudCOSXMLService (ImageHelper) @@ -495,6 +506,46 @@ COS 文档预览方法. /// 提交一个音乐评分任务 -(void)VocalScore:(QCloudVocalScoreRequest *)request; +/// 查询文件处理队列 +/// 本接口用于查询文件处理队列 +-(void)DescribeFileProcessQueues:(QCloudDescribeFileProcessQueuesRequest *)request; + +/// 查询文件解压结果 +/// 本接口用于主动查询指定的文件解压任务结果 +-(void)DescribeFileUnzipJobs:(QCloudDescribeFileUnzipJobsRequest *)request; + +/// 查询多文件打包压缩结果 +/// 本接口用于主动查询指定的多文件打包压缩任务结果 +-(void)DescribeFileZipProcessJobs:(QCloudDescribeFileZipProcessJobsRequest *)request; + +/// 提交多文件打包压缩任务 +/// 多文件打包压缩功能可以将您的多个文件,打包为 zip 等压缩包格式,以提交任务的方式进行多文件打包压缩,异步返回打包后的文件,该接口属于 POST 请求 +-(void)CreateFileZipProcessJobs:(QCloudCreateFileZipProcessJobsRequest *)request; + +/// 哈希值计算同步请求 +/// 以同步请求的方式进行文件哈希值计算,实时返回计算得到的哈希值,该接口属于 GET 请求 +-(void)CreateHashProcessJobs:(QCloudCreateHashProcessJobsRequest *)request; + +/// 查询哈希值计算结果 +/// 本接口用于主动查询指定的文件哈希值计算任务结果 +-(void)DescribeHashProcessJobs:(QCloudDescribeHashProcessJobsRequest *)request; + +/// 提交文件解压任务 +/// 以提交任务的方式进行压缩包文件的解压缩,异步返回压缩包内的全部或部分文件,该接口属于 POST 请求 +-(void)PostFileUnzipProcessJob:(QCloudPostFileUnzipProcessJobRequest *)request; + +/// 提交哈希值计算任务 +/// 以提交任务的方式进行文件哈希值计算,异步返回计算得到的哈希值,该接口属于 POST 请求 +-(void)PosthashProcessJobs:(QCloudPostHashProcessJobsRequest *)request; + +/// 更新文件处理队列 +/// 本接口用于更新文件处理的队列 +-(void)UpdateFileProcessQueue:(QCloudUpdateFileProcessQueueRequest *)request; + +/// 压缩包预览 +/// 该接口可以在不解压文件的情况下预览压缩包内的内容,包含文件数量、名称、文件时间等,接口为同步请求方式 +-(void)ZipFilePreview:(QCloudZipFilePreviewRequest *)request; + @end diff --git a/QCloudCOSXML/Classes/CI/QCloudCOSXMLService+ImageHelper.m b/QCloudCOSXML/Classes/CI/QCloudCOSXMLService+ImageHelper.m index d9b36ce..1c17e9b 100644 --- a/QCloudCOSXML/Classes/CI/QCloudCOSXMLService+ImageHelper.m +++ b/QCloudCOSXML/Classes/CI/QCloudCOSXMLService+ImageHelper.m @@ -107,6 +107,17 @@ #import "QCloudPostSoundHoundRequest.h" #import "QCloudVocalScoreRequest.h" #import "QCloudCIUploadOperationsRequest.h" +#import "QCloudDescribeFileProcessQueuesRequest.h" +#import "QCloudDescribeFileUnzipJobsRequest.h" +#import "QCloudDescribeFileZipProcessJobsRequest.h" +#import "QCloudCreateFileZipProcessJobsRequest.h" +#import "QCloudCreateHashProcessJobsRequest.h" +#import "QCloudDescribeHashProcessJobsRequest.h" +#import "QCloudPostFileUnzipProcessJobRequest.h" +#import "QCloudPostHashProcessJobsRequest.h" +#import "QCloudUpdateFileProcessQueueRequest.h" +#import "QCloudZipFilePreviewRequest.h" + @implementation QCloudCOSXMLService (ImageHelper) @@ -287,7 +298,31 @@ -(void)buildRequestUrl:(QCloudBizHTTPRequest *)request{ [request onError:error]; return; } + __block NSString *requestURLString = urlRequest.URL.absoluteString; + + if (request.credential) { + QCloudAuthentationV5Creator *creator = [[QCloudAuthentationV5Creator alloc] initWithCredential:request.credential]; + QCloudSignature *signature = [creator signatureForData:(NSMutableURLRequest *)urlRequest]; + NSString *authorizatioinString = signature.signature; + if ([requestURLString hasSuffix:@"&"] || [requestURLString hasSuffix:@"?"]) { + requestURLString = [requestURLString stringByAppendingString:authorizatioinString]; + } else if([requestURLString containsString:@"?"] && ![requestURLString hasSuffix:@"&"]){ + requestURLString = [requestURLString stringByAppendingFormat:@"&%@", authorizatioinString]; + }else { + requestURLString = [requestURLString stringByAppendingFormat:@"?%@", authorizatioinString]; + } + if (signature.token) { + requestURLString = + [requestURLString stringByAppendingFormat:@"&x-cos-security-token=%@", signature.token]; + } + + if (request.finishBlock) { + request.finishBlock(requestURLString, nil); + } + return; + } + [request.signatureProvider signatureWithFields:request.signatureFields request:request urlRequest:(NSMutableURLRequest *)urlRequest @@ -582,4 +617,45 @@ - (void)UploadOperations:(QCloudCIUploadOperationsRequest *)request{ } +-(void)DescribeFileProcessQueues:(QCloudDescribeFileProcessQueuesRequest *)request{ + [super performRequest:(QCloudDescribeFileProcessQueuesRequest *)request]; +} + +-(void)DescribeFileUnzipJobs:(QCloudDescribeFileUnzipJobsRequest *)request{ + [super performRequest:(QCloudDescribeFileUnzipJobsRequest *)request]; +} + +-(void)DescribeFileZipProcessJobs:(QCloudDescribeFileZipProcessJobsRequest *)request{ + [super performRequest:(QCloudDescribeFileZipProcessJobsRequest *)request]; +} + +-(void)CreateFileZipProcessJobs:(QCloudCreateFileZipProcessJobsRequest *)request{ + [super performRequest:(QCloudCreateFileZipProcessJobsRequest *)request]; +} + +-(void)CreateHashProcessJobs:(QCloudCreateHashProcessJobsRequest *)request{ + [super performRequest:(QCloudCreateHashProcessJobsRequest *)request]; +} + +-(void)DescribeHashProcessJobs:(QCloudDescribeHashProcessJobsRequest *)request{ + [super performRequest:(QCloudDescribeHashProcessJobsRequest *)request]; +} + +-(void)PostFileUnzipProcessJob:(QCloudPostFileUnzipProcessJobRequest *)request{ + [super performRequest:(QCloudPostFileUnzipProcessJobRequest *)request]; +} + +-(void)PosthashProcessJobs:(QCloudPostHashProcessJobsRequest *)request{ + [super performRequest:(QCloudPostHashProcessJobsRequest *)request]; +} + +-(void)UpdateFileProcessQueue:(QCloudUpdateFileProcessQueueRequest *)request{ + [super performRequest:(QCloudUpdateFileProcessQueueRequest *)request]; +} + +-(void)ZipFilePreview:(QCloudZipFilePreviewRequest *)request{ + [super performRequest:(QCloudZipFilePreviewRequest *)request]; +} + + @end diff --git a/QCloudCOSXML/Classes/CI/model/QCloudCICommonModel.h b/QCloudCOSXML/Classes/CI/model/QCloudCICommonModel.h index 93915a6..5644425 100644 --- a/QCloudCOSXML/Classes/CI/model/QCloudCICommonModel.h +++ b/QCloudCOSXML/Classes/CI/model/QCloudCICommonModel.h @@ -44,6 +44,27 @@ @class QCloudVoiceSynthesisTempleteResponseTemplate; @class QCloudVoiceSynthesisTempleteResponseTtsTpl; +@class QCloudPostFileUnzipProcessJobOutput; +@class QCloudPostFileUnzipProcessJobResponseJobsDetail; +@class QCloudPostFileUnzipProcessJobResponseInput; +@class QCloudPostFileUnzipProcessJobResponseOperation; +@class QCloudFileUncompressConfig; +@class QCloudDownloadConfig; +@class QCloudFileUncompressResult; +@class QCloudCreateFileZipProcessJobsResponseJobsDetail; +@class QCloudCreateFileZipProcessJobsResponseOperation; +@class QCloudCreateFileZipProcessJobsOutput; +@class QCloudFileCompressConfig; +@class QCloudFileCompressResult; +@class QCloudPostHashProcessJobsResponseJobsDetail; +@class QCloudPostHashProcessJobsResponseInput; +@class QCloudPostHashProcessJobsResponseOperation; +@class QCloudPostHashProcessJobsFileHashCodeConfig; +@class QCloudPostHashProcessJobsFileHashCodeResult; +@class QCloudQueueList; + +@class QCloudFileListContents; +@class QCloudFileListContent; NS_ASSUME_NONNULL_BEGIN @interface QCloudCallBackMqConfig : NSObject @@ -898,4 +919,397 @@ NS_ASSUME_NONNULL_BEGIN @end +@interface QCloudPostFileUnzipProcessJobOutput : NSObject + +/// 存储桶的地域。;是否必传:是 +@property (nonatomic,strong) NSString * Region; + +/// 保存解压后文件的存储桶。;是否必传:是 +@property (nonatomic,strong) NSString * Bucket; + +@end + +@interface QCloudPostFileUnzipProcessJobResponseJobsDetail : NSObject + +/// 错误码,只有 State 为 Failed 时有意义。 +@property (nonatomic,strong) NSString * Code; + +/// 错误描述,只有 State 为 Failed 时有意义。 +@property (nonatomic,strong) NSString * Message; + +/// 新创建任务的 ID。 +@property (nonatomic,strong) NSString * JobId; + +/// 表示任务的类型,文件解压默认为:FileUncompress。 +@property (nonatomic,strong) NSString * Tag; + +/// 任务状态Submitted:已提交,待执行Running:执行中Success:执行成功Failed:执行失败Pause:任务暂停,当暂停队列时,待执行的任务会变为暂停状态Cancel:任务被取消执行 +@property (nonatomic,strong) NSString * State; + +/// 任务进度百分比,范围为[0, 100]。 +@property (nonatomic,assign) NSInteger Progress; + +/// 任务的创建时间。 +@property (nonatomic,strong) NSString * CreationTime; + +/// 任务的开始时间。 +@property (nonatomic,strong) NSString * StartTime; + +/// 任务的结束时间。 +@property (nonatomic,strong) NSString * EndTime; + +/// 任务所属的 队列 ID。 +@property (nonatomic,strong) NSString * QueueId; + +/// 被解压文件的信息。 +@property (nonatomic,strong) QCloudPostFileUnzipProcessJobResponseInput * Input; + +/// 文件解压的处理规则。 +@property (nonatomic,strong) QCloudPostFileUnzipProcessJobResponseOperation * Operation; + +@end + +@interface QCloudPostFileUnzipProcessJobResponseInput : NSObject + +/// 存储桶所在地域。 +@property (nonatomic,strong) NSString * Region; + +/// 文件所在的存储桶。 +@property (nonatomic,strong) NSString * BucketId; + +/// 被解压文件的文件名。 +@property (nonatomic,strong) NSString * Object; + +@end + +@interface QCloudPostFileUnzipProcessJobResponseOperation : NSObject + +/// 透传用户信息。 +@property (nonatomic,strong) NSString * UserData; + +/// 同请求中的 Request.Operation.Output。 +@property (nonatomic,strong) QCloudPostFileUnzipProcessJobOutput * Output; + +/// 同请求中的 Request.Operation.FileUncompressConfig。 +@property (nonatomic,strong) QCloudFileUncompressConfig * FileUncompressConfig; + +/// 文件解压的结果,任务未完成时不返回。 +@property (nonatomic,strong) QCloudFileUncompressResult * FileUncompressResult; + +@end + +@interface QCloudFileUncompressConfig : NSObject + +/// 指定解压后输出文件的前缀,不填则默认保存在存储桶根路径。;是否必传:否 +@property (nonatomic,strong) NSString * Prefix; + +/// 解压密钥,传入时需先经过 base64编码。;是否必传:否 +@property (nonatomic,strong) NSString * UnCompressKey; + +/// 指定解压后的文件路径是否需要替换前缀,有效值:0:不添加额外的前缀,解压缩将保存在 Prefix 指定的路径下(不会保留压缩包的名称,仅将压缩包内的文件保存至指定的路径)1:以压缩包本身的名称作为前缀,解压缩将保存在 Prefix 指定的路径下2:以压缩包完整路径作为前缀,此时如果不指定 Prefix,就是解压到压缩包所在的当前路径(包含压缩包本身名称)默认值为0。;是否必传:否 +@property (nonatomic,strong) NSString * PrefixReplaced; + +/// 解压模式0:全部下载1:解压指定内容默认值为0;是否必传:否 +@property (nonatomic,strong) NSString * Mode ; + +/// 解压指定内容配置,当 Mode = 1 时必填;是否必传:否 +@property (nonatomic,strong) QCloudDownloadConfig * DownloadConfig; + +/// 指定查询任务或查看任务回调时,是否需要输出已解压的文件列表。输出的列表将在查询任务响应或回调中的字段下展示。限制说明:仅支持展示前1000条文件,1000条以后的文件记录将被截断。如需查看更多文件,建议通过 COS GET Bucket 接口查询。;是否必传:否 +@property (nonatomic,assign) BOOL ListingFile; + +@end + +@interface QCloudDownloadConfig : NSObject + +/// 解压该前缀下的文件;是否必传:是 +@property (nonatomic,strong) NSString * Prefix ; + +/// 解压该文件,最多同时填 1000 个;是否必传:是 +@property (nonatomic,strong) NSString * Key ; + +@end + + +@interface QCloudFileUncompressResult : NSObject + +/// 解压后文件保存的存储桶的地域。 +@property (nonatomic,strong) NSString * Region; + +/// 解压后文件保存的存储桶。 +@property (nonatomic,strong) NSString * Bucket; + +/// 解压后文件的个数。 +@property (nonatomic,strong) NSString * FileCount; + +/// 提交解压任务时指定了为 true 时,并且任务状态为已成功完成时返回该节点,表示已解压的文件列表。 限制说明:仅支持展示前1000条文件,1000条以后的文件记录将被截断。 如需查看更多文件,建议通过 COS GET Bucket 接口查询。;是否必传:否 +@property (nonatomic,strong) QCloudFileListContents * FileList; + +@end + +@interface QCloudFileListContents : NSObject + +@property (nonatomic,assign) BOOL IsTruncated; + +/// 已解压的文件信息,可包含多条。;是否必传:否 +@property (nonatomic,strong)NSArray * Contents; + +@end + +@interface QCloudFileListContent : NSObject + +/// 文件名称。;是否必传:否 +@property (nonatomic,strong) NSString * Key; + +/// 文件的最近一次修改的时间。;是否必传:否 +@property (nonatomic,strong) NSString * LastModified; + +/// 文件大小。;是否必传:否 +@property (nonatomic,assign) NSInteger FileSize; + + +@end + +@interface QCloudCreateFileZipProcessJobsResponseJobsDetail : NSObject + +/// 错误码,只有 State 为 Failed 时有意义。 +@property (nonatomic,strong) NSString * Code; + +/// 错误描述,只有 State 为 Failed 时有意义。 +@property (nonatomic,strong) NSString * Message; + +/// 新创建任务的 ID。 +@property (nonatomic,strong) NSString * JobId; + +/// 表示任务的类型,多文件打包压缩默认为:FileCompress。 +@property (nonatomic,strong) NSString * Tag; + +/// 任务状态Submitted:已提交,待执行。Running:执行中。Success:执行成功。Failed:执行失败。Pause:任务暂停,当暂停队列时,待执行的任务会变为暂停状态。Cancel:任务被取消执行。 +@property (nonatomic,strong) NSString * State; + +/// 任务进度百分比,范围为[0, 100]。 +@property (nonatomic,assign) NSInteger Progress; + +/// 任务的创建时间。 +@property (nonatomic,strong) NSString * CreationTime; + +/// 任务的开始时间。 +@property (nonatomic,strong) NSString * StartTime; + +/// 任务的结束时间。 +@property (nonatomic,strong) NSString * EndTime; + +/// 任务所属的 队列 ID。 +@property (nonatomic,strong) NSString * QueueId; + +@property (nonatomic,strong) NSString * QueueType; +/// 多文件打包压缩的处理规则。 +@property (nonatomic,strong) QCloudCreateFileZipProcessJobsResponseOperation * Operation; + +@end + +@interface QCloudCreateFileZipProcessJobsResponseOperation : NSObject + +/// 透传用户信息。 +@property (nonatomic,strong) NSString * UserData; + +/// 同请求中的 Request.Operation.Output。 +@property (nonatomic,strong) QCloudCreateFileZipProcessJobsOutput * Output; + +/// 同请求中的 Request.Operation.FileCompressConfig。 +@property (nonatomic,strong) QCloudFileCompressConfig * FileCompressConfig; + +/// 多文件打包压缩的结果,任务未完成时不返回。 +@property (nonatomic,strong) QCloudFileCompressResult * FileCompressResult; + +@end + +@interface QCloudCreateFileZipProcessJobsOutput : NSObject + +/// 存储桶的地域。;是否必传:是 +@property (nonatomic,strong) NSString * Region; + +/// 保存压缩后文件的存储桶。;是否必传:是 +@property (nonatomic,strong) NSString * Bucket; + +/// 压缩后文件的文件名;是否必传:是 +@property (nonatomic,strong) NSString * Object; + +@end + +@interface QCloudFileCompressConfig : NSObject + +/// 文件打包时,是否需要去除源文件已有的目录结构,有效值:0:不需要去除目录结构,打包后压缩包中的文件会保留原有的目录结构;1:需要,打包后压缩包内的文件会去除原有的目录结构,所有文件都在同一层级。例如:源文件 URL 为 https://domain/source/test.mp4,则源文件路径为 source/test.mp4,如果为 1,则 ZIP 包中该文件路径为 test.mp4;如果为0, ZIP 包中该文件路径为 source/test.mp4。;是否必传:是 +@property (nonatomic,strong) NSString * Flatten; + +/// 打包压缩的类型,有效值:zip、tar、tar.gz。;是否必传:是 +@property (nonatomic,strong) NSString * Format; + +/// 压缩类型,仅在Format为tar.gz或zip时有效。faster:压缩速度较快better:压缩质量较高,体积较小default:适中的压缩方式默认值为default;是否必传:否 +@property (nonatomic,strong) NSString * Type; + +/// 压缩包密钥,传入时需先经过 base64 编码,编码后长度不能超过128。当 Format 为 zip 时生效。;是否必传:否 +@property (nonatomic,strong) NSString * CompressKey; + +/// 支持将需要打包的文件整理成索引文件,后台将根据索引文件内提供的文件 url,打包为一个压缩包文件。索引文件需要保存在当前存储桶中,本字段需要提供索引文件的对象地址,不需要带域名,填写示例:/test/index.csv索引文件格式:仅支持 CSV 文件,一行一条 URL(仅支持本存储桶文件),如有多列字段,默认取第一列作为URL。;是否必传:否 +@property (nonatomic,strong) NSString * UrlList; + +/// 支持对存储桶中的某个前缀进行打包,如果需要对某个目录进行打包,需要加/,例如test目录打包,则值为:test/。;是否必传:否 +@property (nonatomic,strong) NSString * Prefix; + +/// 支持对存储桶中的多个文件进行打包,个数不能超过 1000,如需打包更多文件,请使用UrlList或Prefix参数。;是否必传:否 +@property (nonatomic,strong) NSString * Key; + +/// 打包时如果单个文件出错,是否忽略错误继续打包。有效值为:ture:忽略错误继续打包后续的文件;false:遇到某个文件执行打包报错时,直接终止打包任务,不返回压缩包。默认值为false。;是否必传:否 +@property (nonatomic,strong) NSString * IgnoreError ; + +@end + +@interface QCloudFileCompressResult : NSObject + +/// 打包压缩后文件保存的存储桶的地域。 +@property (nonatomic,strong) NSString * Region; + +/// 打包压缩后文件保存的存储桶。 +@property (nonatomic,strong) NSString * Bucket; + +/// 打包压缩后文件的名称。 +@property (nonatomic,strong) NSString * Object; + +/// 打包文件的总数 +@property (nonatomic,strong) NSString * CompressFileCount ; + +/// 打包时出错的文件数 +@property (nonatomic,strong) NSString * ErrorCount; + +@end + +@interface QCloudPostHashProcessJobsResponseJobsDetail : NSObject + +/// 错误码,只有 State 为 Failed 时有意义。 +@property (nonatomic,strong) NSString * Code; + +/// 错误描述,只有 State 为 Failed 时有意义。 +@property (nonatomic,strong) NSString * Message; + +/// 创建任务的 ID。 +@property (nonatomic,strong) NSString * JobId; + +/// 表示任务的类型,哈希值计算默认为:FileHashCode。 +@property (nonatomic,strong) NSString * Tag; + +/// 任务状态Submitted:已提交,待执行。Running:执行中。Success:执行成功。Failed:执行失败。Pause:任务暂停,当暂停队列时,待执行的任务会变为暂停状态。Cancel:任务被取消执行。 +@property (nonatomic,strong) NSString * State; + +/// 任务进度百分比,范围为[0, 100]。 +@property (nonatomic,assign) NSInteger Progress; + +/// 任务的创建时间。 +@property (nonatomic,strong) NSString * CreationTime; + +/// 任务的开始时间。 +@property (nonatomic,strong) NSString * StartTime; + +/// 任务的结束时间。 +@property (nonatomic,strong) NSString * EndTime; + +/// 任务所属的 队列 ID。 +@property (nonatomic,strong) NSString * QueueId; + +@property (nonatomic,strong) NSString * QueueType; + +/// 被计算哈希值的文件信息。 +@property (nonatomic,strong) QCloudPostHashProcessJobsResponseInput * Input; + +/// 哈希值计算的处理规则。 +@property (nonatomic,strong) QCloudPostHashProcessJobsResponseOperation * Operation; + +@end + +@interface QCloudPostHashProcessJobsResponseInput : NSObject + +/// 存储桶所在地域。 +@property (nonatomic,strong) NSString * Region; + +/// 文件所在的存储桶。 +@property (nonatomic,strong) NSString * BucketId; + +/// 被计算哈希值的文件名。 +@property (nonatomic,strong) NSString * Object; + +@end + +@interface QCloudPostHashProcessJobsResponseOperation : NSObject + +/// 透传用户信息。 +@property (nonatomic,strong) NSString * UserData; + +/// 同请求中的 Request.Operation.FileHashCodeConfig。 +@property (nonatomic,strong) QCloudPostHashProcessJobsFileHashCodeConfig * FileHashCodeConfig; + +/// 计算得到的文件 hash 值信息,任务未完成时不返回。 +@property (nonatomic,strong) QCloudPostHashProcessJobsFileHashCodeResult * FileHashCodeResult; + +@end + +@interface QCloudPostHashProcessJobsFileHashCodeConfig : NSObject + +/// 哈希值的算法类型,支持:MD5、SHA1、SHA256;是否必传:是 +@property (nonatomic,strong) NSString * Type; + +/// 是否将计算得到的哈希值添加至文件自定义header,有效值:true、false,默认值为 false。自定义 header 根据Type的值变化,例如Type值为MD5时,自定义 header 为 x-cos-meta-md5。;是否必传:否 +@property (nonatomic,strong) NSString * AddToHeader; + +@end + +@interface QCloudPostHashProcessJobsFileHashCodeResult : NSObject + +/// MD5 计算结果。 +@property (nonatomic,strong) NSString * MD5; + +/// SHA1 计算结果。 +@property (nonatomic,strong) NSString * SHA1; + +/// SHA256 计算结果。 +@property (nonatomic,strong) NSString * SHA256; + +/// 文件大小。 +@property (nonatomic,assign) NSInteger FileSize; + +/// 文件的最后修改时间。 +@property (nonatomic,strong) NSString * LastModified; + +/// 文件的Etag。 +@property (nonatomic,strong) NSString * Etag; + +@end + +@interface QCloudQueueList : NSObject + +/// 队列 ID +@property (nonatomic,strong) NSString * QueueId; + +/// 队列名字 +@property (nonatomic,strong) NSString * Name; + +/// 当前状态,Active 或者 Paused +@property (nonatomic,strong) NSString * State; + +/// 回调配置 +@property (nonatomic,strong) QCloudNotifyConfig * NotifyConfig; + +/// 队列最大长度 +@property (nonatomic,assign) NSInteger MaxSize; + +/// 当前队列最大并行执行的任务数 +@property (nonatomic,assign) NSInteger MaxConcurrent; + +/// 更新时间 +@property (nonatomic,strong) NSString * UpdateTime; + +/// 创建时间 +@property (nonatomic,strong) NSString * CreateTime; + +@end + NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/model/QCloudCICommonModel.m b/QCloudCOSXML/Classes/CI/model/QCloudCICommonModel.m index a5a96f1..38a95d8 100644 --- a/QCloudCOSXML/Classes/CI/model/QCloudCICommonModel.m +++ b/QCloudCOSXML/Classes/CI/model/QCloudCICommonModel.m @@ -286,3 +286,159 @@ + (NSDictionary *)modelContainerPropertyGenericClass { @implementation QCloudVoiceSynthesisTempleteResponseTtsTpl @end + + +@implementation QCloudPostFileUnzipProcessJobOutput + +@end + +@implementation QCloudPostFileUnzipProcessJobResponseJobsDetail + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Input" : [QCloudPostFileUnzipProcessJobResponseInput class], + @"Operation" : [QCloudPostFileUnzipProcessJobResponseOperation class], + }; +} + +@end + +@implementation QCloudPostFileUnzipProcessJobResponseInput + +@end + +@implementation QCloudPostFileUnzipProcessJobResponseOperation + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Output" : [QCloudPostFileUnzipProcessJobOutput class], + @"FileUncompressConfig" : [QCloudFileUncompressConfig class], + @"FileUncompressResult" : [QCloudFileUncompressResult class], + }; +} + +@end + +@implementation QCloudFileUncompressConfig + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"DownloadConfig" : [QCloudDownloadConfig class], + }; +} + +@end + +@implementation QCloudDownloadConfig + +@end + +@implementation QCloudFileUncompressResult + +@end + +@implementation QCloudCreateFileZipProcessJobsResponseJobsDetail + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Operation" : [QCloudCreateFileZipProcessJobsResponseOperation class], + }; +} + +@end + +@implementation QCloudCreateFileZipProcessJobsResponseOperation + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Output" : [QCloudCreateFileZipProcessJobsOutput class], + @"FileCompressConfig" : [QCloudFileCompressConfig class], + @"FileCompressResult" : [QCloudFileCompressResult class], + }; +} + +@end + +@implementation QCloudCreateFileZipProcessJobsOutput + +@end + +@implementation QCloudFileCompressConfig + +@end + +@implementation QCloudFileCompressResult + +@end + +@implementation QCloudPostHashProcessJobsResponseJobsDetail + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Input" : [QCloudPostHashProcessJobsResponseInput class], + @"Operation" : [QCloudPostHashProcessJobsResponseOperation class], + }; +} + +@end + +@implementation QCloudPostHashProcessJobsResponseInput + +@end + +@implementation QCloudPostHashProcessJobsResponseOperation + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"FileHashCodeConfig" : [QCloudPostHashProcessJobsFileHashCodeConfig class], + @"FileHashCodeResult" : [QCloudPostHashProcessJobsFileHashCodeResult class], + }; +} + +@end + +@implementation QCloudPostHashProcessJobsFileHashCodeConfig + +@end + +@implementation QCloudPostHashProcessJobsFileHashCodeResult + +@end + +@implementation QCloudQueueList + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"NotifyConfig" : [QCloudNotifyConfig class], + }; +} + +@end + +@implementation QCloudFileListContents + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Contents" : [QCloudFileListContent class], + }; +} + +- (NSDictionary *)modelCustomWillTransformFromDictionary:(NSDictionary *)dic { + + if (!dic) {return dic;} + + if (![dic isKindOfClass:[NSDictionary class]]) {return nil;} + + if (dic[@"Contents"] && [dic[@"Contents"] isKindOfClass:[NSDictionary class]]){ + NSMutableDictionary * mdic = [NSMutableDictionary dictionaryWithDictionary:dic]; + [mdic setValue:@[dic[@"Contents"]] forKey:@"Contents"]; + dic = mdic.copy; + } + return dic; +} + +@end + +@implementation QCloudFileListContent + +@end diff --git a/QCloudCOSXML/Classes/CI/model/QCloudCreateFileZipProcessJobsResponse.h b/QCloudCOSXML/Classes/CI/model/QCloudCreateFileZipProcessJobsResponse.h new file mode 100644 index 0000000..85f460e --- /dev/null +++ b/QCloudCOSXML/Classes/CI/model/QCloudCreateFileZipProcessJobsResponse.h @@ -0,0 +1,83 @@ +// +// QCloudCreateFileZipProcessJobsResponse.h +// QCloudCreateFileZipProcessJobsResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCICommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@class QCloudCreateFileZipProcessJobsOperation; +@interface QCloudCreateFileZipProcessJobsResponse : NSObject + +/// 任务的详细信息。 +@property (nonatomic,strong)NSArray * JobsDetail; + +@end + +@interface QCloudCreateFileZipProcessJobs : NSObject + +/// 表示任务的类型,多文件打��压缩默认为:FileCompress。;是否必传:是 +@property (nonatomic,strong) NSString * Tag; + +/// 包含文件打包压缩的处理规则。;是否必传:是 +@property (nonatomic,strong) QCloudCreateFileZipProcessJobsOperation * Operation; + +/// 任务回调格式,JSON 或 XML,默认 XML,优先级高于队列的回调格式。;是否必传:否 +@property (nonatomic,strong) NSString * CallBackFormat; + +/// 任务回调类型,Url 或 TDMQ,默认 Url,优先级高于队列的回调类型。;是否必传:否 +@property (nonatomic,strong) NSString * CallBackType; + +/// 任务回调的地址,优先级高于队列的回调地址。;是否必传:否 +@property (nonatomic,strong) NSString * CallBack; + +/// 任务回调 TDMQ 配置,当 CallBackType 为 TDMQ 时必填。详情请参见 CallBackMqConfig。;是否必传:否 +@property (nonatomic,strong) QCloudCallBackMqConfig * CallBackMqConfig; + +@end + +@interface QCloudCreateFileZipProcessJobsOperation : NSObject + +/// 指定文件打包压缩的处理规则。;是否必传:是 +@property (nonatomic,strong) QCloudFileCompressConfig * FileCompressConfig; + +/// 透传用户信息,可打印的 ASCII 码,长度不超过1024。;是否必传:否 +@property (nonatomic,strong) NSString * UserData; + +/// 指定打包压缩后的文件保存的地址信息。;是否必传:是 +@property (nonatomic,strong) QCloudCreateFileZipProcessJobsOutput * Output; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/model/QCloudCreateFileZipProcessJobsResponse.m b/QCloudCOSXML/Classes/CI/model/QCloudCreateFileZipProcessJobsResponse.m new file mode 100644 index 0000000..e5d2313 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/model/QCloudCreateFileZipProcessJobsResponse.m @@ -0,0 +1,85 @@ +// +// QCloudCreateFileZipProcessJobsResponse.m +// QCloudCreateFileZipProcessJobsResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudCreateFileZipProcessJobsResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudCreateFileZipProcessJobsResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"JobsDetail" : [QCloudCreateFileZipProcessJobsResponseJobsDetail class], + }; +} + +- (NSDictionary *)modelCustomWillTransformFromDictionary:(NSDictionary *)dic { + + if (!dic) {return dic;} + + if (![dic isKindOfClass:[NSDictionary class]]) {return nil;} + + if (dic[@"JobsDetail"] && [dic[@"JobsDetail"] isKindOfClass:[NSDictionary class]]){ + NSMutableDictionary * mdic = [NSMutableDictionary dictionaryWithDictionary:dic]; + [mdic setValue:@[dic[@"JobsDetail"]] forKey:@"JobsDetail"]; + dic = mdic.copy; + } + return dic; +} + +@end + +@implementation QCloudCreateFileZipProcessJobs + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Operation" : [QCloudCreateFileZipProcessJobsOperation class], + @"CallBackMqConfig" : [QCloudCallBackMqConfig class], + }; +} + +@end + +@implementation QCloudCreateFileZipProcessJobsOperation + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"FileCompressConfig" : [QCloudFileCompressConfig class], + @"Output" : [QCloudCreateFileZipProcessJobsOutput class], + }; +} + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/model/QCloudCreateHashProcessJobsResponse.h b/QCloudCOSXML/Classes/CI/model/QCloudCreateHashProcessJobsResponse.h new file mode 100644 index 0000000..c8fb8b7 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/model/QCloudCreateHashProcessJobsResponse.h @@ -0,0 +1,87 @@ +// +// QCloudCreateHashProcessJobsResponse.h +// QCloudCreateHashProcessJobsResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCICommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@class QCloudCreateHashProcessJobsResponseFileHashCodeResult; +@class QCloudCreateHashProcessJobsResponseInput; +@interface QCloudCreateHashProcessJobsResponse : NSObject + +/// 文件哈希值的结果。 +@property (nonatomic,strong) QCloudCreateHashProcessJobsResponseFileHashCodeResult * FileHashCodeResult; + +/// 输入文件的基本信息。 +@property (nonatomic,strong) QCloudCreateHashProcessJobsResponseInput * Input; + +@end + +@interface QCloudCreateHashProcessJobsResponseFileHashCodeResult : NSObject + +/// 请求时type为 md5 时返回 +@property (nonatomic,strong) NSString * MD5; + +/// 请求时type为 sha1 时返回 +@property (nonatomic,strong) NSString * SHA1; + +/// 请求时type为 sha256 时返回 +@property (nonatomic,strong) NSString * SHA256; + +/// 文件的大小 +@property (nonatomic,assign) NSInteger FileSize; + +/// 对象的最近一次修改的时间 +@property (nonatomic,strong) NSString * LastModified; + +/// ETag 全称为 Entity Tag,是对象被创建时标识对象内容的信息标签,可用于检查对象的内容是否发生变化 +@property (nonatomic,strong) NSString * Etag; + +@end + +@interface QCloudCreateHashProcessJobsResponseInput : NSObject + +/// 存储桶所在地域 +@property (nonatomic,strong) NSString * Region; + +/// 输入文件所在的存储桶 +@property (nonatomic,strong) NSString * Bucket; + +/// 输入文件在存储桶中的名称 +@property (nonatomic,strong) NSString * Object; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/model/QCloudCreateHashProcessJobsResponse.m b/QCloudCOSXML/Classes/CI/model/QCloudCreateHashProcessJobsResponse.m new file mode 100644 index 0000000..95fca2e --- /dev/null +++ b/QCloudCOSXML/Classes/CI/model/QCloudCreateHashProcessJobsResponse.m @@ -0,0 +1,58 @@ +// +// QCloudCreateHashProcessJobsResponse.m +// QCloudCreateHashProcessJobsResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudCreateHashProcessJobsResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudCreateHashProcessJobsResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"FileHashCodeResult" : [QCloudCreateHashProcessJobsResponseFileHashCodeResult class], + @"Input" : [QCloudCreateHashProcessJobsResponseInput class], + }; +} + +@end + +@implementation QCloudCreateHashProcessJobsResponseFileHashCodeResult + +@end + +@implementation QCloudCreateHashProcessJobsResponseInput + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/model/QCloudDescribeFileProcessQueuesResponse.h b/QCloudCOSXML/Classes/CI/model/QCloudDescribeFileProcessQueuesResponse.h new file mode 100644 index 0000000..ee3562e --- /dev/null +++ b/QCloudCOSXML/Classes/CI/model/QCloudDescribeFileProcessQueuesResponse.h @@ -0,0 +1,123 @@ +// +// QCloudDescribeFileProcessQueuesResponse.h +// QCloudDescribeFileProcessQueuesResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCICommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@class QCloudDescribeFileProcessQueuesResponseQueueList; +@class QCloudDescribeFileProcessQueuesResponseNotifyConfig; +@interface QCloudDescribeFileProcessQueuesResponse : NSObject + +/// 请求的唯一 ID +@property (nonatomic,strong) NSString * RequestId; + +/// 队列总数 +@property (nonatomic,assign) NSInteger TotalCount; + +/// 当前页数,同请求中的 pageNumber +@property (nonatomic,assign) NSInteger PageNumber; + +/// 每页个数,同请求中的 pageSize +@property (nonatomic,assign) NSInteger PageSize; + +/// 队列数组 +@property (nonatomic,strong)NSArray * QueueList; + +/// 不存在的队列 ID 列表 +@property (nonatomic,strong) NSString * NonExistPIDs; + +@end + +@interface QCloudDescribeFileProcessQueuesResponseQueueList : NSObject + +/// 队列 ID +@property (nonatomic,strong) NSString * QueueId; + +/// 队列名字 +@property (nonatomic,strong) NSString * Name; + +/// 当前状态,Active 或者 Paused +@property (nonatomic,strong) NSString * State; + +/// 回调配置 +@property (nonatomic,strong) QCloudDescribeFileProcessQueuesResponseNotifyConfig * NotifyConfig; + +/// 队列最大长度 +@property (nonatomic,assign) NSInteger MaxSize; + +/// 当前队列最大并行执行的任务数 +@property (nonatomic,assign) NSInteger MaxConcurrent; + +/// 队列类型 +@property (nonatomic,strong) NSString * Category; + +/// 更新时间 +@property (nonatomic,strong) NSString * UpdateTime; + +/// 创建时间 +@property (nonatomic,strong) NSString * CreateTime; + +@end + +@interface QCloudDescribeFileProcessQueuesResponseNotifyConfig : NSObject + +/// 回调地址 +@property (nonatomic,strong) NSString * Url; + +/// 开关状态 +@property (nonatomic,strong) NSString * State; + +/// 回调类型 +@property (nonatomic,strong) NSString * Type; + +/// 回调事件 +@property (nonatomic,strong) NSString * Event; + +/// 回调类型 +@property (nonatomic,strong) NSString * ResultFormat; + +/// TDMQ 使用模式 +@property (nonatomic,strong) NSString * MqMode; + +/// TDMQ 所属园区 +@property (nonatomic,strong) NSString * MqRegion; + +/// TDMQ 主题名称 +@property (nonatomic,strong) NSString * MqName; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/model/QCloudDescribeFileProcessQueuesResponse.m b/QCloudCOSXML/Classes/CI/model/QCloudDescribeFileProcessQueuesResponse.m new file mode 100644 index 0000000..75b5553 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/model/QCloudDescribeFileProcessQueuesResponse.m @@ -0,0 +1,77 @@ +// +// QCloudDescribeFileProcessQueuesResponse.m +// QCloudDescribeFileProcessQueuesResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDescribeFileProcessQueuesResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudDescribeFileProcessQueuesResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"QueueList" : [QCloudDescribeFileProcessQueuesResponseQueueList class], + }; +} + +- (NSDictionary *)modelCustomWillTransformFromDictionary:(NSDictionary *)dic { + + if (!dic) {return dic;} + + if (![dic isKindOfClass:[NSDictionary class]]) {return nil;} + + if (dic[@"QueueList"] && [dic[@"QueueList"] isKindOfClass:[NSDictionary class]]){ + NSMutableDictionary * mdic = [NSMutableDictionary dictionaryWithDictionary:dic]; + [mdic setValue:@[dic[@"QueueList"]] forKey:@"QueueList"]; + dic = mdic.copy; + } + return dic; +} + +@end + +@implementation QCloudDescribeFileProcessQueuesResponseQueueList + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"NotifyConfig" : [QCloudDescribeFileProcessQueuesResponseNotifyConfig class], + }; +} + +@end + +@implementation QCloudDescribeFileProcessQueuesResponseNotifyConfig + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/model/QCloudDescribeFileUnzipJobsResponse.h b/QCloudCOSXML/Classes/CI/model/QCloudDescribeFileUnzipJobsResponse.h new file mode 100644 index 0000000..4fbf731 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/model/QCloudDescribeFileUnzipJobsResponse.h @@ -0,0 +1,50 @@ +// +// QCloudDescribeFileUnzipJobsResponse.h +// QCloudDescribeFileUnzipJobsResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCICommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@interface QCloudDescribeFileUnzipJobsResponse : NSObject + +/// 同提交文件解压任务接口中的 Response.JobsDetail +@property (nonatomic,strong)NSArray * JobsDetail; + +/// 查询的 ID 中不存在任务,所有任务都存在时不返回 +@property (nonatomic,strong) NSString * NonExistJobIds; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/model/QCloudDescribeFileUnzipJobsResponse.m b/QCloudCOSXML/Classes/CI/model/QCloudDescribeFileUnzipJobsResponse.m new file mode 100644 index 0000000..7e13b90 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/model/QCloudDescribeFileUnzipJobsResponse.m @@ -0,0 +1,63 @@ +// +// QCloudDescribeFileUnzipJobsResponse.m +// QCloudDescribeFileUnzipJobsResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDescribeFileUnzipJobsResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudDescribeFileUnzipJobsResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"JobsDetail" : [QCloudPostFileUnzipProcessJobResponseJobsDetail class], + }; +} + +- (NSDictionary *)modelCustomWillTransformFromDictionary:(NSDictionary *)dic { + + if (!dic) {return dic;} + + if (![dic isKindOfClass:[NSDictionary class]]) {return nil;} + + if (dic[@"JobsDetail"] && [dic[@"JobsDetail"] isKindOfClass:[NSDictionary class]]){ + NSMutableDictionary * mdic = [NSMutableDictionary dictionaryWithDictionary:dic]; + [mdic setValue:@[dic[@"JobsDetail"]] forKey:@"JobsDetail"]; + dic = mdic.copy; + } + return dic; +} + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/model/QCloudDescribeFileZipProcessJobsResponse.h b/QCloudCOSXML/Classes/CI/model/QCloudDescribeFileZipProcessJobsResponse.h new file mode 100644 index 0000000..d589701 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/model/QCloudDescribeFileZipProcessJobsResponse.h @@ -0,0 +1,50 @@ +// +// QCloudDescribeFileZipProcessJobsResponse.h +// QCloudDescribeFileZipProcessJobsResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCICommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@interface QCloudDescribeFileZipProcessJobsResponse : NSObject + +/// 同提交多文件打包任务接口中的 Response.JobsDetail +@property (nonatomic,strong)NSArray * JobsDetail; + +/// 查询的 ID 中不存在任务,所有任务都存在时不返回。 +@property (nonatomic,strong) NSString * NonExistJobIds; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/model/QCloudDescribeFileZipProcessJobsResponse.m b/QCloudCOSXML/Classes/CI/model/QCloudDescribeFileZipProcessJobsResponse.m new file mode 100644 index 0000000..413b548 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/model/QCloudDescribeFileZipProcessJobsResponse.m @@ -0,0 +1,63 @@ +// +// QCloudDescribeFileZipProcessJobsResponse.m +// QCloudDescribeFileZipProcessJobsResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDescribeFileZipProcessJobsResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudDescribeFileZipProcessJobsResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"JobsDetail" : [QCloudCreateFileZipProcessJobsResponseJobsDetail class], + }; +} + +- (NSDictionary *)modelCustomWillTransformFromDictionary:(NSDictionary *)dic { + + if (!dic) {return dic;} + + if (![dic isKindOfClass:[NSDictionary class]]) {return nil;} + + if (dic[@"JobsDetail"] && [dic[@"JobsDetail"] isKindOfClass:[NSDictionary class]]){ + NSMutableDictionary * mdic = [NSMutableDictionary dictionaryWithDictionary:dic]; + [mdic setValue:@[dic[@"JobsDetail"]] forKey:@"JobsDetail"]; + dic = mdic.copy; + } + return dic; +} + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/model/QCloudDescribeHashProcessJobsResponse.h b/QCloudCOSXML/Classes/CI/model/QCloudDescribeHashProcessJobsResponse.h new file mode 100644 index 0000000..fe63f26 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/model/QCloudDescribeHashProcessJobsResponse.h @@ -0,0 +1,50 @@ +// +// QCloudDescribeHashProcessJobsResponse.h +// QCloudDescribeHashProcessJobsResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCICommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@interface QCloudDescribeHashProcessJobsResponse : NSObject + +/// 同提交哈希值计算接口中的 Response.JobsDetail +@property (nonatomic,strong)NSArray * JobsDetail; + +/// 查询的 ID 中不存在任务,所有任务都存在时不返回。 +@property (nonatomic,strong) NSString * NonExistJobIds; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/model/QCloudDescribeHashProcessJobsResponse.m b/QCloudCOSXML/Classes/CI/model/QCloudDescribeHashProcessJobsResponse.m new file mode 100644 index 0000000..b55d706 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/model/QCloudDescribeHashProcessJobsResponse.m @@ -0,0 +1,63 @@ +// +// QCloudDescribeHashProcessJobsResponse.m +// QCloudDescribeHashProcessJobsResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDescribeHashProcessJobsResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudDescribeHashProcessJobsResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"JobsDetail" : [QCloudPostHashProcessJobsResponseJobsDetail class], + }; +} + +- (NSDictionary *)modelCustomWillTransformFromDictionary:(NSDictionary *)dic { + + if (!dic) {return dic;} + + if (![dic isKindOfClass:[NSDictionary class]]) {return nil;} + + if (dic[@"JobsDetail"] && [dic[@"JobsDetail"] isKindOfClass:[NSDictionary class]]){ + NSMutableDictionary * mdic = [NSMutableDictionary dictionaryWithDictionary:dic]; + [mdic setValue:@[dic[@"JobsDetail"]] forKey:@"JobsDetail"]; + dic = mdic.copy; + } + return dic; +} + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/model/QCloudPostFileUnzipProcessJobResponse.h b/QCloudCOSXML/Classes/CI/model/QCloudPostFileUnzipProcessJobResponse.h new file mode 100644 index 0000000..ff90a59 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/model/QCloudPostFileUnzipProcessJobResponse.h @@ -0,0 +1,95 @@ +// +// QCloudPostFileUnzipProcessJobResponse.h +// QCloudPostFileUnzipProcessJobResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCICommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@class QCloudPostFileUnzipProcessJobInput; +@class QCloudPostFileUnzipProcessJobOperation; +@interface QCloudPostFileUnzipProcessJobResponse : NSObject + +/// 任务的详细信息。 +@property (nonatomic,strong)NSArray * JobsDetail; + +@end + +@interface QCloudPostFileUnzipProcessJob : NSObject + +/// 表示任务的类型,文件解压默认为:FileUncompress。;是否必传:是 +@property (nonatomic,strong) NSString * Tag; + +/// 包含待操作的文件信息。;是否必传:是 +@property (nonatomic,strong) QCloudPostFileUnzipProcessJobInput * Input; + +/// 包含文件解压的处理规则。;是否必传:是 +@property (nonatomic,strong) QCloudPostFileUnzipProcessJobOperation * Operation; + +/// 任务回调格式,JSON 或 XML,默认 XML,优先级高于队列的回调格式。;是否必传:否 +@property (nonatomic,strong) NSString * CallBackFormat; + +/// 任务回调类型,Url 或 TDMQ,默认 Url,优先级高于队列的回调类型。;是否必传:否 +@property (nonatomic,strong) NSString * CallBackType; + +/// 任务回调的地址,优先级高于队列的回调地址。;是否必传:否 +@property (nonatomic,strong) NSString * CallBack; + +/// 任务回调 TDMQ 配置,当 CallBackType 为 TDMQ 时必填。详情见 CallBackMqConfig。;是否必传:否 +@property (nonatomic,strong) QCloudCallBackMqConfig * CallBackMqConfig; + +@end + +@interface QCloudPostFileUnzipProcessJobInput : NSObject + +/// 文件名,取值为文件在当前存储桶中的完整名称。;是否必传:是 +@property (nonatomic,strong) NSString * Object; + +@end + +@interface QCloudPostFileUnzipProcessJobOperation : NSObject + +/// 指定文件解压的处理规则。;是否必传:是 +@property (nonatomic,strong) QCloudFileUncompressConfig * FileUncompressConfig; + +/// 透传用户信息,可打印的 ASCII 码,长度不超过1024。;是否必传:否 +@property (nonatomic,strong) NSString * UserData; + +/// 指定解压后的文件保存的存储桶信息。;是否必传:是 +@property (nonatomic,strong) QCloudPostFileUnzipProcessJobOutput * Output; + +@property (nonatomic,assign) NSInteger JobLevel; +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/model/QCloudPostFileUnzipProcessJobResponse.m b/QCloudCOSXML/Classes/CI/model/QCloudPostFileUnzipProcessJobResponse.m new file mode 100644 index 0000000..aff132f --- /dev/null +++ b/QCloudCOSXML/Classes/CI/model/QCloudPostFileUnzipProcessJobResponse.m @@ -0,0 +1,90 @@ +// +// QCloudPostFileUnzipProcessJobResponse.m +// QCloudPostFileUnzipProcessJobResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudPostFileUnzipProcessJobResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudPostFileUnzipProcessJobResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"JobsDetail" : [QCloudPostFileUnzipProcessJobResponseJobsDetail class], + }; +} + +- (NSDictionary *)modelCustomWillTransformFromDictionary:(NSDictionary *)dic { + + if (!dic) {return dic;} + + if (![dic isKindOfClass:[NSDictionary class]]) {return nil;} + + if (dic[@"JobsDetail"] && [dic[@"JobsDetail"] isKindOfClass:[NSDictionary class]]){ + NSMutableDictionary * mdic = [NSMutableDictionary dictionaryWithDictionary:dic]; + [mdic setValue:@[dic[@"JobsDetail"]] forKey:@"JobsDetail"]; + dic = mdic.copy; + } + return dic; +} + +@end + +@implementation QCloudPostFileUnzipProcessJob + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Input" : [QCloudPostFileUnzipProcessJobInput class], + @"Operation" : [QCloudPostFileUnzipProcessJobOperation class], + @"CallBackMqConfig" : [QCloudCallBackMqConfig class], + }; +} + +@end + +@implementation QCloudPostFileUnzipProcessJobInput + +@end + +@implementation QCloudPostFileUnzipProcessJobOperation + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"FileUncompressConfig" : [QCloudFileUncompressConfig class], + @"Output" : [QCloudPostFileUnzipProcessJobOutput class], + }; +} + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/model/QCloudPostHashProcessJobsResponse.h b/QCloudCOSXML/Classes/CI/model/QCloudPostHashProcessJobsResponse.h new file mode 100644 index 0000000..d44776d --- /dev/null +++ b/QCloudCOSXML/Classes/CI/model/QCloudPostHashProcessJobsResponse.h @@ -0,0 +1,91 @@ +// +// QCloudPostHashProcessJobsResponse.h +// QCloudPostHashProcessJobsResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCICommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@class QCloudPostHashProcessJobsInput; +@class QCloudPostHashProcessJobsOperation; +@interface QCloudPostHashProcessJobsResponse : NSObject + +/// 任务的详细信息。 +@property (nonatomic,strong)NSArray * JobsDetail; + +@end + +@interface QCloudPostHashProcessJobs : NSObject + +/// 表示任务的类型,哈希值计算默认为:FileHashCode。;是否必传:是 +@property (nonatomic,strong) NSString * Tag; + +/// 包含待操作的文件信息。;是否必传:是 +@property (nonatomic,strong) QCloudPostHashProcessJobsInput * Input; + +/// 包含哈希值计算的处理规则。;是否必传:是 +@property (nonatomic,strong) QCloudPostHashProcessJobsOperation * Operation; + +/// 任务回调格式,JSON 或 XML,默认 XML,优先级高于队列的回调格式。;是否必传:否 +@property (nonatomic,strong) NSString * CallBackFormat; + +/// 任务回调类型,Url 或 TDMQ,默认 Url,优先级高于队列的回调类型。;是否必传:否 +@property (nonatomic,strong) NSString * CallBackType; + +/// 任务回调的地址,优先级高于队列的回调地址。;是否必传:否 +@property (nonatomic,strong) NSString * CallBack; + +/// 任务回调 TDMQ 配置,当 CallBackType 为 TDMQ 时必填。详情见 CallBackMqConfig。;是否必传:否 +@property (nonatomic,strong) QCloudCallBackMqConfig * CallBackMqConfig; + +@end + +@interface QCloudPostHashProcessJobsInput : NSObject + +/// 文件名,取值为文件在当前存储桶中的完整名称。;是否必传:是 +@property (nonatomic,strong) NSString * Object; + +@end + +@interface QCloudPostHashProcessJobsOperation : NSObject + +/// 指定哈希值计算的处理规则。;是否必传:是 +@property (nonatomic,strong) QCloudPostHashProcessJobsFileHashCodeConfig * FileHashCodeConfig; + +/// 透传用户信息, 可打印的 ASCII 码,长度不超过1024。;是否必传:否 +@property (nonatomic,strong) NSString * UserData; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/model/QCloudPostHashProcessJobsResponse.m b/QCloudCOSXML/Classes/CI/model/QCloudPostHashProcessJobsResponse.m new file mode 100644 index 0000000..1730428 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/model/QCloudPostHashProcessJobsResponse.m @@ -0,0 +1,89 @@ +// +// QCloudPostHashProcessJobsResponse.m +// QCloudPostHashProcessJobsResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudPostHashProcessJobsResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudPostHashProcessJobsResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"JobsDetail" : [QCloudPostHashProcessJobsResponseJobsDetail class], + }; +} + +- (NSDictionary *)modelCustomWillTransformFromDictionary:(NSDictionary *)dic { + + if (!dic) {return dic;} + + if (![dic isKindOfClass:[NSDictionary class]]) {return nil;} + + if (dic[@"JobsDetail"] && [dic[@"JobsDetail"] isKindOfClass:[NSDictionary class]]){ + NSMutableDictionary * mdic = [NSMutableDictionary dictionaryWithDictionary:dic]; + [mdic setValue:@[dic[@"JobsDetail"]] forKey:@"JobsDetail"]; + dic = mdic.copy; + } + return dic; +} + +@end + +@implementation QCloudPostHashProcessJobs + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Input" : [QCloudPostHashProcessJobsInput class], + @"Operation" : [QCloudPostHashProcessJobsOperation class], + @"CallBackMqConfig" : [QCloudCallBackMqConfig class], + }; +} + +@end + +@implementation QCloudPostHashProcessJobsInput + +@end + +@implementation QCloudPostHashProcessJobsOperation + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"FileHashCodeConfig" : [QCloudPostHashProcessJobsFileHashCodeConfig class], + }; +} + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/model/QCloudUpdateFileProcessQueueResponse.h b/QCloudCOSXML/Classes/CI/model/QCloudUpdateFileProcessQueueResponse.h new file mode 100644 index 0000000..55cacdb --- /dev/null +++ b/QCloudCOSXML/Classes/CI/model/QCloudUpdateFileProcessQueueResponse.h @@ -0,0 +1,63 @@ +// +// QCloudUpdateFileProcessQueueResponse.h +// QCloudUpdateFileProcessQueueResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCICommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@interface QCloudUpdateFileProcessQueueResponse : NSObject + +/// 请求的唯一 ID +@property (nonatomic,strong) NSString * RequestId; + +/// 队列信息 +@property (nonatomic,strong) QCloudQueueList * Queue; + +@end + +@interface QCloudUpdateFileProcessQueue : NSObject + +/// 队列名称,仅支持中文、英文、数字、_、-和*,长度不超过 128;是否必传:是 +@property (nonatomic,strong) NSString * Name; + +/// Active 表示队列内的作业会被调度执行Paused 表示队列暂停,作业不再会被调度执行,队列内的所有作业状态维持在暂停状态,已经执行中的任务不受影响;是否必传:是 +@property (nonatomic,strong) NSString * State; + +/// 回调配置;是否必传:是 +@property (nonatomic,strong) QCloudNotifyConfig * NotifyConfig; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/model/QCloudUpdateFileProcessQueueResponse.m b/QCloudCOSXML/Classes/CI/model/QCloudUpdateFileProcessQueueResponse.m new file mode 100644 index 0000000..1f2a757 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/model/QCloudUpdateFileProcessQueueResponse.m @@ -0,0 +1,59 @@ +// +// QCloudUpdateFileProcessQueueResponse.m +// QCloudUpdateFileProcessQueueResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudUpdateFileProcessQueueResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudUpdateFileProcessQueueResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Queue" : [QCloudQueueList class], + }; +} + +@end + +@implementation QCloudUpdateFileProcessQueue + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"NotifyConfig" : [QCloudNotifyConfig class], + }; +} + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/model/QCloudZipFilePreviewResponse.h b/QCloudCOSXML/Classes/CI/model/QCloudZipFilePreviewResponse.h new file mode 100644 index 0000000..40f0d1e --- /dev/null +++ b/QCloudCOSXML/Classes/CI/model/QCloudZipFilePreviewResponse.h @@ -0,0 +1,67 @@ +// +// QCloudZipFilePreviewResponse.h +// QCloudZipFilePreviewResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCICommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@class QCloudZipFilePreviewResponseContents; +@interface QCloudZipFilePreviewResponse : NSObject + +/// 压缩包中的文件数量 +@property (nonatomic,assign) NSInteger FileNumber; + +/// 是否被截断,压缩包预览最多支持预览前1000个文件 +@property (nonatomic,assign) BOOL IsTruncated; + +/// 保存文件信息的容器 +@property (nonatomic,strong)NSArray * Contents; + +@end + +@interface QCloudZipFilePreviewResponseContents : NSObject + +/// 文件名称 +@property (nonatomic,strong) NSString * Key; + +/// 文件的最近一次修改的时间 +@property (nonatomic,strong) NSString * LastModified; + +/// 文件压缩前的大小 +@property (nonatomic,assign) NSInteger UncompressedSize; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/model/QCloudZipFilePreviewResponse.m b/QCloudCOSXML/Classes/CI/model/QCloudZipFilePreviewResponse.m new file mode 100644 index 0000000..64e12a2 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/model/QCloudZipFilePreviewResponse.m @@ -0,0 +1,67 @@ +// +// QCloudZipFilePreviewResponse.m +// QCloudZipFilePreviewResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudZipFilePreviewResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudZipFilePreviewResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Contents" : [QCloudZipFilePreviewResponseContents class], + }; +} + +- (NSDictionary *)modelCustomWillTransformFromDictionary:(NSDictionary *)dic { + + if (!dic) {return dic;} + + if (![dic isKindOfClass:[NSDictionary class]]) {return nil;} + + if (dic[@"Contents"] && [dic[@"Contents"] isKindOfClass:[NSDictionary class]]){ + NSMutableDictionary * mdic = [NSMutableDictionary dictionaryWithDictionary:dic]; + [mdic setValue:@[dic[@"Contents"]] forKey:@"Contents"]; + dic = mdic.copy; + } + return dic; +} + +@end + +@implementation QCloudZipFilePreviewResponseContents + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/request/QCloudCreateFileZipProcessJobsRequest.h b/QCloudCOSXML/Classes/CI/request/QCloudCreateFileZipProcessJobsRequest.h new file mode 100644 index 0000000..a7fb7b2 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/request/QCloudCreateFileZipProcessJobsRequest.h @@ -0,0 +1,91 @@ +// +// QCloudCreateFileZipProcessJobsRequest.h +// QCloudCreateFileZipProcessJobsRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCreateFileZipProcessJobsResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 提交多文件打包压缩任务. + + ### 功能描述 + + 多文件打包压缩功能可以将您的多个文件,打包为 zip 等压缩包格式,以提交任务的方式进行多文件打包压缩,异步返回打包后的文件,该接口属于 POST 请求 + + 具体请查看 https://cloud.tencent.com/document/product/460/83091 + +### 示例 + + @code + + QCloudCreateFileZipProcessJobsRequest * request = [QCloudCreateFileZipProcessJobsRequest new]; + request.bucket = @"sample-1250000000"; + request.regionName = @"COS_REGIONNAME"; + request.input = [QCloudCreateFileZipProcessJobs new]; + // 表示任务的类型,多文件打��压缩默认为:FileCompress。;是否必传:是 + request.input.Tag = @"FileCompress"; + // 包含文件打包压缩的处理规则。;是否必传:是 + request.input.Operation = [QCloudCreateFileZipProcessJobsOperation new]; + request.input.Operation.FileCompressConfig = [QCloudFileCompressConfig new]; + request.input.Operation.FileCompressConfig.Flatten = @"1"; + request.input.Operation.FileCompressConfig.Format = @"zip"; + request.input.Operation.FileCompressConfig.Prefix = @"/"; + request.input.Operation.Output = [QCloudCreateFileZipProcessJobsOutput new]; + request.input.Operation.Output.Region = @"ap-chongqing"; + request.input.Operation.Output.Bucket = @"sample-1250000000"; + request.input.Operation.Output.Object = @"test123.zip"; + + [request setFinishBlock:^(QCloudCreateFileZipProcessJobsResponse * outputObject, NSError *error) { + // result:QCloudCreateFileZipProcessJobsResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/83091 + }]; + [[QCloudCOSXMLService defaultCOSXML] CreateFileZipProcessJobs:request]; + + +*/ + +@interface QCloudCreateFileZipProcessJobsRequest : QCloudBizHTTPRequest + +/// 存储桶名称 +@property (nonatomic,strong)NSString * bucket; + +/// 请求输入参数 +@property (nonatomic,strong)QCloudCreateFileZipProcessJobs * input; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudCreateFileZipProcessJobsResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/request/QCloudCreateFileZipProcessJobsRequest.m b/QCloudCOSXML/Classes/CI/request/QCloudCreateFileZipProcessJobsRequest.m new file mode 100644 index 0000000..07a19f0 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/request/QCloudCreateFileZipProcessJobsRequest.m @@ -0,0 +1,82 @@ +// +// QCloudCreateFileZipProcessJobsRequest.m +// QCloudCreateFileZipProcessJobsRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudCreateFileZipProcessJobsRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudCreateFileZipProcessJobsRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + QCloudURLFuseWithXMLParamters, + QCloudURLFuseContentMD5Base64StyleHeaders + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseXMLSerializerBlock, + QCloudResponseObjectSerilizerBlock([QCloudCreateFileZipProcessJobsResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"post"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [self.runOnService.configuration.endpoint serverURLWithBucket:self.bucket appID:self.runOnService.configuration.appID regionName:self.regionName]; + NSString * serverUrlString = __serverURL.absoluteString; + + serverUrlString = [serverUrlString stringByReplacingOccurrencesOfString:@".cos." withString:@".ci."]; + __serverURL = [NSURL URLWithString:serverUrlString]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"jobs"]; + self.requestData.URIComponents = __pathComponents; + + [self.requestData setParameter:[self.input qcloud_modelToJSONObject] withKey:@"Request"]; + + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudCreateFileZipProcessJobsResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/request/QCloudCreateHashProcessJobsRequest.h b/QCloudCOSXML/Classes/CI/request/QCloudCreateHashProcessJobsRequest.h new file mode 100644 index 0000000..15c41f9 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/request/QCloudCreateHashProcessJobsRequest.h @@ -0,0 +1,89 @@ +// +// QCloudCreateHashProcessJobsRequest.h +// QCloudCreateHashProcessJobsRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCreateHashProcessJobsResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 哈希值计算同步请求. + + ### 功能描述 + + 以同步请求的方式进行文件哈希值计算,实时返回计算得到的哈希值,该接口属于 GET 请求 + + 具体请查看 https://cloud.tencent.com/document/product/460/83084 + +### 示例 + + @code + + QCloudCreateHashProcessJobsRequest * request = [QCloudCreateHashProcessJobsRequest new]; + request.bucket = @"sample-1250000000"; + request.regionName = @"COS_REGIONNAME"; + // 设置:ObjectKey; + request.ObjectKey = @"test.zip"; + request.type = @"md5"; + + [request setFinishBlock:^(QCloudCreateHashProcessJobsResponse * outputObject, NSError *error) { + // result:QCloudCreateHashProcessJobsResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/83084 + }]; + [[QCloudCOSXMLService defaultCOSXML] CreateHashProcessJobs:request]; + + +*/ + +@interface QCloudCreateHashProcessJobsRequest : QCloudBizHTTPRequest + +/// 操作类型,哈希值计算固定为:filehash;是否必传:是 +@property (nonatomic,strong) NSString * ciProcess; + +/// 支持的哈希算法类型,有效值:md5、sha1、sha256;是否必传:是 +@property (nonatomic,strong) NSString * type; + +/// 是否将计算得到的哈希值,自动添加至文件的自定义 header,格式为:x-cos-meta-md5/sha1/sha256;有效值: true、false,不填则默认为 false;是否必传:否 +@property (nonatomic,strong) NSString * addtoheader; + +/// 存储桶名称 +@property (nonatomic,strong)NSString * bucket; + +@property (nonatomic,strong)NSString * ObjectKey; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudCreateHashProcessJobsResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/request/QCloudCreateHashProcessJobsRequest.m b/QCloudCOSXML/Classes/CI/request/QCloudCreateHashProcessJobsRequest.m new file mode 100644 index 0000000..aef46d9 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/request/QCloudCreateHashProcessJobsRequest.m @@ -0,0 +1,84 @@ +// +// QCloudCreateHashProcessJobsRequest.m +// QCloudCreateHashProcessJobsRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudCreateHashProcessJobsRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudCreateHashProcessJobsRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseXMLSerializerBlock, + QCloudResponseObjectSerilizerBlock([QCloudCreateHashProcessJobsResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"get"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [self.runOnService.configuration.endpoint serverURLWithBucket:self.bucket appID:self.runOnService.configuration.appID regionName:self.regionName]; + + self.requestData.serverURL = __serverURL.absoluteString; + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + if(self.ObjectKey){ + [__pathComponents addObject:self.ObjectKey]; + } + self.requestData.URIComponents = __pathComponents; + + [self.requestData setQueryStringParamter:self.ciProcess?:@"filehash" withKey:@"ci-process"]; + + if (self.type) { + [self.requestData setQueryStringParamter:self.type withKey:@"type"]; + } + if (self.addtoheader) { + [self.requestData setQueryStringParamter:self.addtoheader withKey:@"addtoheader"]; + } + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudCreateHashProcessJobsResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/request/QCloudDescribeFileProcessQueuesRequest.h b/QCloudCOSXML/Classes/CI/request/QCloudDescribeFileProcessQueuesRequest.h new file mode 100644 index 0000000..8d37bdc --- /dev/null +++ b/QCloudCOSXML/Classes/CI/request/QCloudDescribeFileProcessQueuesRequest.h @@ -0,0 +1,87 @@ +// +// QCloudDescribeFileProcessQueuesRequest.h +// QCloudDescribeFileProcessQueuesRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudDescribeFileProcessQueuesResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 查询文件处理队列. + + ### 功能描述 + + 本接口用于查询文件处理队列 + + 具体请查看 https://cloud.tencent.com/document/product/460/86421 + +### 示例 + + @code + + QCloudDescribeFileProcessQueuesRequest * request = [QCloudDescribeFileProcessQueuesRequest new]; + request.bucket = @"sample-1250000000"; + request.regionName = @"COS_REGIONNAME"; + + [request setFinishBlock:^(QCloudDescribeFileProcessQueuesResponse * outputObject, NSError *error) { + // result:QCloudDescribeFileProcessQueuesResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/86421 + }]; + [[QCloudCOSXMLService defaultCOSXML] DescribeFileProcessQueues:request]; + + +*/ + +@interface QCloudDescribeFileProcessQueuesRequest : QCloudBizHTTPRequest + +/// 队列 ID,以“,”符号分割字符串;是否必传:否 +@property (nonatomic,strong) NSString * queueIds; + +/// Active 表示队列内的作业会被调度执行Paused 表示队列暂停,作业不再会被调度执行,队列内的所有作业状态维持在暂停状态,已经执行中的任务不受影响;是否必传:否 +@property (nonatomic,strong) NSString * state; + +/// 第几页,默认值1;是否必传:否 +@property (nonatomic,strong) NSString * pageNumber; + +/// 每页个数,默认值10;是否必传:否 +@property (nonatomic,strong) NSString * pageSize; + +/// 存储桶名称 +@property (nonatomic,strong)NSString * bucket; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudDescribeFileProcessQueuesResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/request/QCloudDescribeFileProcessQueuesRequest.m b/QCloudCOSXML/Classes/CI/request/QCloudDescribeFileProcessQueuesRequest.m new file mode 100644 index 0000000..e61e552 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/request/QCloudDescribeFileProcessQueuesRequest.m @@ -0,0 +1,90 @@ +// +// QCloudDescribeFileProcessQueuesRequest.m +// QCloudDescribeFileProcessQueuesRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDescribeFileProcessQueuesRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudDescribeFileProcessQueuesRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseXMLSerializerBlock, + QCloudResponseObjectSerilizerBlock([QCloudDescribeFileProcessQueuesResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"get"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [self.runOnService.configuration.endpoint serverURLWithBucket:self.bucket appID:self.runOnService.configuration.appID regionName:self.regionName]; + NSString * serverUrlString = __serverURL.absoluteString; + + serverUrlString = [serverUrlString stringByReplacingOccurrencesOfString:@".cos." withString:@".ci."]; + __serverURL = [NSURL URLWithString:serverUrlString]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"file_queue"]; + self.requestData.URIComponents = __pathComponents; + + if (self.queueIds) { + [self.requestData setQueryStringParamter:self.queueIds withKey:@"queueIds"]; + } + if (self.state) { + [self.requestData setQueryStringParamter:self.state withKey:@"state"]; + } + if (self.pageNumber) { + [self.requestData setQueryStringParamter:self.pageNumber withKey:@"pageNumber"]; + } + if (self.pageSize) { + [self.requestData setQueryStringParamter:self.pageSize withKey:@"pageSize"]; + } + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudDescribeFileProcessQueuesResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/request/QCloudDescribeFileUnzipJobsRequest.h b/QCloudCOSXML/Classes/CI/request/QCloudDescribeFileUnzipJobsRequest.h new file mode 100644 index 0000000..b02b154 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/request/QCloudDescribeFileUnzipJobsRequest.h @@ -0,0 +1,79 @@ +// +// QCloudDescribeFileUnzipJobsRequest.h +// QCloudDescribeFileUnzipJobsRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudDescribeFileUnzipJobsResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 查询文件解压结果. + + ### 功能描述 + + 本接口用于主动查询指定的文件解压任务结果 + + 具体请查看 https://cloud.tencent.com/document/product/460/83088 + +### 示例 + + @code + + QCloudDescribeFileUnzipJobsRequest * request = [QCloudDescribeFileUnzipJobsRequest new]; + request.bucket = @"sample-1250000000"; + request.regionName = @"COS_REGIONNAME"; + // 设置:jobId; + request.jobId = @"jobId"; + + [request setFinishBlock:^(QCloudDescribeFileUnzipJobsResponse * outputObject, NSError *error) { + // result:QCloudDescribeFileUnzipJobsResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/83088 + }]; + [[QCloudCOSXMLService defaultCOSXML] DescribeFileUnzipJobs:request]; + + +*/ + +@interface QCloudDescribeFileUnzipJobsRequest : QCloudBizHTTPRequest + +/// 存储桶名称 +@property (nonatomic,strong)NSString * bucket; + +@property (nonatomic,strong)NSString * jobId; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudDescribeFileUnzipJobsResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/request/QCloudDescribeFileUnzipJobsRequest.m b/QCloudCOSXML/Classes/CI/request/QCloudDescribeFileUnzipJobsRequest.m new file mode 100644 index 0000000..1308569 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/request/QCloudDescribeFileUnzipJobsRequest.m @@ -0,0 +1,81 @@ +// +// QCloudDescribeFileUnzipJobsRequest.m +// QCloudDescribeFileUnzipJobsRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDescribeFileUnzipJobsRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudDescribeFileUnzipJobsRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseXMLSerializerBlock, + QCloudResponseObjectSerilizerBlock([QCloudDescribeFileUnzipJobsResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"get"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [self.runOnService.configuration.endpoint serverURLWithBucket:self.bucket appID:self.runOnService.configuration.appID regionName:self.regionName]; + NSString * serverUrlString = __serverURL.absoluteString; + + serverUrlString = [serverUrlString stringByReplacingOccurrencesOfString:@".cos." withString:@".ci."]; + __serverURL = [NSURL URLWithString:serverUrlString]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"file_jobs"]; + if(self.jobId){ + [__pathComponents addObject:self.jobId]; + } + self.requestData.URIComponents = __pathComponents; + + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudDescribeFileUnzipJobsResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/request/QCloudDescribeFileZipProcessJobsRequest.h b/QCloudCOSXML/Classes/CI/request/QCloudDescribeFileZipProcessJobsRequest.h new file mode 100644 index 0000000..20a9cc1 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/request/QCloudDescribeFileZipProcessJobsRequest.h @@ -0,0 +1,79 @@ +// +// QCloudDescribeFileZipProcessJobsRequest.h +// QCloudDescribeFileZipProcessJobsRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudDescribeFileZipProcessJobsResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 查询多文件打包压缩结果. + + ### 功能描述 + + 本接口用于主动查询指定的多文件打包压缩任务结果 + + 具体请查看 https://cloud.tencent.com/document/product/460/83092 + +### 示例 + + @code + + QCloudDescribeFileZipProcessJobsRequest * request = [QCloudDescribeFileZipProcessJobsRequest new]; + request.bucket = @"sample-1250000000"; + request.regionName = @"COS_REGIONNAME"; + // 设置:jobId; + request.jobId = @"jobId"; + + [request setFinishBlock:^(QCloudDescribeFileZipProcessJobsResponse * outputObject, NSError *error) { + // result:QCloudDescribeFileZipProcessJobsResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/83092 + }]; + [[QCloudCOSXMLService defaultCOSXML] DescribeFileZipProcessJobs:request]; + + +*/ + +@interface QCloudDescribeFileZipProcessJobsRequest : QCloudBizHTTPRequest + +/// 存储桶名称 +@property (nonatomic,strong)NSString * bucket; + +@property (nonatomic,strong)NSString * jobId; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudDescribeFileZipProcessJobsResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/request/QCloudDescribeFileZipProcessJobsRequest.m b/QCloudCOSXML/Classes/CI/request/QCloudDescribeFileZipProcessJobsRequest.m new file mode 100644 index 0000000..e74be43 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/request/QCloudDescribeFileZipProcessJobsRequest.m @@ -0,0 +1,81 @@ +// +// QCloudDescribeFileZipProcessJobsRequest.m +// QCloudDescribeFileZipProcessJobsRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDescribeFileZipProcessJobsRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudDescribeFileZipProcessJobsRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseXMLSerializerBlock, + QCloudResponseObjectSerilizerBlock([QCloudDescribeFileZipProcessJobsResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"get"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [self.runOnService.configuration.endpoint serverURLWithBucket:self.bucket appID:self.runOnService.configuration.appID regionName:self.regionName]; + NSString * serverUrlString = __serverURL.absoluteString; + + serverUrlString = [serverUrlString stringByReplacingOccurrencesOfString:@".cos." withString:@".ci."]; + __serverURL = [NSURL URLWithString:serverUrlString]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"jobs"]; + if(self.jobId){ + [__pathComponents addObject:self.jobId]; + } + self.requestData.URIComponents = __pathComponents; + + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudDescribeFileZipProcessJobsResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/request/QCloudDescribeHashProcessJobsRequest.h b/QCloudCOSXML/Classes/CI/request/QCloudDescribeHashProcessJobsRequest.h new file mode 100644 index 0000000..93f1285 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/request/QCloudDescribeHashProcessJobsRequest.h @@ -0,0 +1,79 @@ +// +// QCloudDescribeHashProcessJobsRequest.h +// QCloudDescribeHashProcessJobsRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudDescribeHashProcessJobsResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 查询哈希值计算结果. + + ### 功能描述 + + 本接口用于主动查询指定的文件哈希值计算任务结果 + + 具体请查看 https://cloud.tencent.com/document/product/460/83086 + +### 示例 + + @code + + QCloudDescribeHashProcessJobsRequest * request = [QCloudDescribeHashProcessJobsRequest new]; + request.bucket = @"sample-1250000000"; + request.regionName = @"COS_REGIONNAME"; + // 设置:jobId; + request.jobId = @"jobId"; + + [request setFinishBlock:^(QCloudDescribeHashProcessJobsResponse * outputObject, NSError *error) { + // result:QCloudDescribeHashProcessJobsResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/83086 + }]; + [[QCloudCOSXMLService defaultCOSXML] DescribeHashProcessJobs:request]; + + +*/ + +@interface QCloudDescribeHashProcessJobsRequest : QCloudBizHTTPRequest + +/// 存储桶名称 +@property (nonatomic,strong)NSString * bucket; + +@property (nonatomic,strong)NSString * jobId; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudDescribeHashProcessJobsResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/request/QCloudDescribeHashProcessJobsRequest.m b/QCloudCOSXML/Classes/CI/request/QCloudDescribeHashProcessJobsRequest.m new file mode 100644 index 0000000..f012fd6 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/request/QCloudDescribeHashProcessJobsRequest.m @@ -0,0 +1,81 @@ +// +// QCloudDescribeHashProcessJobsRequest.m +// QCloudDescribeHashProcessJobsRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDescribeHashProcessJobsRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudDescribeHashProcessJobsRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseXMLSerializerBlock, + QCloudResponseObjectSerilizerBlock([QCloudDescribeHashProcessJobsResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"get"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [self.runOnService.configuration.endpoint serverURLWithBucket:self.bucket appID:self.runOnService.configuration.appID regionName:self.regionName]; + NSString * serverUrlString = __serverURL.absoluteString; + + serverUrlString = [serverUrlString stringByReplacingOccurrencesOfString:@".cos." withString:@".ci."]; + __serverURL = [NSURL URLWithString:serverUrlString]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"file_jobs"]; + if(self.jobId){ + [__pathComponents addObject:self.jobId]; + } + self.requestData.URIComponents = __pathComponents; + + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudDescribeHashProcessJobsResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/request/QCloudPostFileUnzipProcessJobRequest.h b/QCloudCOSXML/Classes/CI/request/QCloudPostFileUnzipProcessJobRequest.h new file mode 100644 index 0000000..246ca02 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/request/QCloudPostFileUnzipProcessJobRequest.h @@ -0,0 +1,93 @@ +// +// QCloudPostFileUnzipProcessJobRequest.h +// QCloudPostFileUnzipProcessJobRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudPostFileUnzipProcessJobResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 提交文件解压任务. + + ### 功能描述 + + 以提交任务的方式进行压缩包文件的解压缩,异步返回压缩包内的全部或部分文件,该接口属于 POST 请求 + + 具体请查看 https://cloud.tencent.com/document/product/460/83087 + +### 示例 + + @code + + QCloudPostFileUnzipProcessJobRequest * request = [QCloudPostFileUnzipProcessJobRequest new]; + request.bucket = @"sample-1250000000"; + request.regionName = @"COS_REGIONNAME"; + + request.input = [QCloudPostFileUnzipProcessJob new]; + // 表示任务的类型,文件解压默认为:FileUncompress。;是否必传:是 + request.input.Tag = @"FileUncompress"; + // 包含待操作的文件信息。;是否必传:是 + request.input.Input = [QCloudPostFileUnzipProcessJobInput new]; + // 文件名,取值为文件在当前存储桶中的完整名称。;是否必传:是 + request.input.Input.Object = @"test.zip"; + // 包含文件解压的处理规则。;是否必传:是 + request.input.Operation = [QCloudPostFileUnzipProcessJobOperation new]; + request.input.Operation.FileUncompressConfig = QCloudFileUncompressConfig.new; + request.input.Operation.FileUncompressConfig.Prefix = @"/"; + request.input.Operation.Output = QCloudPostFileUnzipProcessJobOutput.new; + request.input.Operation.Output.Bucket = @"tinna-media-1253960454"; + request.input.Operation.Output.Region = @"ap-chongqing"; + + [request setFinishBlock:^(QCloudPostFileUnzipProcessJobResponse * outputObject, NSError *error) { + // result:QCloudPostFileUnzipProcessJobResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/83087 + }]; + [[QCloudCOSXMLService defaultCOSXML] PostFileUnzipProcessJob:request]; + + +*/ + +@interface QCloudPostFileUnzipProcessJobRequest : QCloudBizHTTPRequest + +/// 存储桶名称 +@property (nonatomic,strong)NSString * bucket; + +/// 请求输入参数 +@property (nonatomic,strong)QCloudPostFileUnzipProcessJob * input; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudPostFileUnzipProcessJobResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/request/QCloudPostFileUnzipProcessJobRequest.m b/QCloudCOSXML/Classes/CI/request/QCloudPostFileUnzipProcessJobRequest.m new file mode 100644 index 0000000..832ad40 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/request/QCloudPostFileUnzipProcessJobRequest.m @@ -0,0 +1,82 @@ +// +// QCloudPostFileUnzipProcessJobRequest.m +// QCloudPostFileUnzipProcessJobRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudPostFileUnzipProcessJobRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudPostFileUnzipProcessJobRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + QCloudURLFuseWithXMLParamters, + QCloudURLFuseContentMD5Base64StyleHeaders + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseXMLSerializerBlock, + QCloudResponseObjectSerilizerBlock([QCloudPostFileUnzipProcessJobResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"post"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [self.runOnService.configuration.endpoint serverURLWithBucket:self.bucket appID:self.runOnService.configuration.appID regionName:self.regionName]; + NSString * serverUrlString = __serverURL.absoluteString; + + serverUrlString = [serverUrlString stringByReplacingOccurrencesOfString:@".cos." withString:@".ci."]; + __serverURL = [NSURL URLWithString:serverUrlString]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"jobs"]; + self.requestData.URIComponents = __pathComponents; + + [self.requestData setParameter:[self.input qcloud_modelToJSONObject] withKey:@"Request"]; + + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudPostFileUnzipProcessJobResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/request/QCloudPostHashProcessJobsRequest.h b/QCloudCOSXML/Classes/CI/request/QCloudPostHashProcessJobsRequest.h new file mode 100644 index 0000000..26d2f24 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/request/QCloudPostHashProcessJobsRequest.h @@ -0,0 +1,90 @@ +// +// QCloudPostHashProcessJobsRequest.h +// QCloudPostHashProcessJobsRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudPostHashProcessJobsResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 提交哈希值计算任务. + + ### 功能描述 + + 以提交任务的方式进行文件哈希值计算,异步返回计算得到的哈希值,该接口属于 POST 请求 + + 具体请查看 https://cloud.tencent.com/document/product/460/83085 + +### 示例 + + @code + + QCloudPostHashProcessJobsRequest * request = [QCloudPostHashProcessJobsRequest new]; + request.bucket = @"sample-1250000000"; + request.regionName = @"COS_REGIONNAME"; + request.input = [QCloudPostHashProcessJobs new]; + // 表示任务的类型,哈希值计算默认为:FileHashCode。;是否必传:是 + request.input.Tag = @"FileHashCode"; + // 包含待操作的文件信息。;是否必传:是 + request.input.Input = [QCloudPostHashProcessJobsInput new]; + // 文件名,取值为文件在当前存储桶中的完整名称。;是否必传:是 + request.input.Input.Object = @"test.zip"; + // 包含哈希值计算的处理规则。;是否必传:是 + request.input.Operation = [QCloudPostHashProcessJobsOperation new]; + // 透传用户信息, 可打印的 ASCII 码,长度不超过1024。;是否必传:否 + request.input.Operation.FileHashCodeConfig = QCloudPostHashProcessJobsFileHashCodeConfig.new; + request.input.Operation.FileHashCodeConfig.Type = @"MD5"; + + [request setFinishBlock:^(QCloudPostHashProcessJobsResponse * outputObject, NSError *error) { + // result:QCloudPostHashProcessJobsResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/83085 + }]; + [[QCloudCOSXMLService defaultCOSXML] PostHashProcessJobs:request]; + + +*/ + +@interface QCloudPostHashProcessJobsRequest : QCloudBizHTTPRequest + +/// 存储桶名称 +@property (nonatomic,strong)NSString * bucket; + +/// 请求输入参数 +@property (nonatomic,strong)QCloudPostHashProcessJobs * input; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudPostHashProcessJobsResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/request/QCloudPostHashProcessJobsRequest.m b/QCloudCOSXML/Classes/CI/request/QCloudPostHashProcessJobsRequest.m new file mode 100644 index 0000000..f8c1b5b --- /dev/null +++ b/QCloudCOSXML/Classes/CI/request/QCloudPostHashProcessJobsRequest.m @@ -0,0 +1,82 @@ +// +// QCloudPostHashProcessJobsRequest.m +// QCloudPostHashProcessJobsRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudPostHashProcessJobsRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudPostHashProcessJobsRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + QCloudURLFuseWithXMLParamters, + QCloudURLFuseContentMD5Base64StyleHeaders + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseXMLSerializerBlock, + QCloudResponseObjectSerilizerBlock([QCloudPostHashProcessJobsResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"post"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [self.runOnService.configuration.endpoint serverURLWithBucket:self.bucket appID:self.runOnService.configuration.appID regionName:self.regionName]; + NSString * serverUrlString = __serverURL.absoluteString; + + serverUrlString = [serverUrlString stringByReplacingOccurrencesOfString:@".cos." withString:@".ci."]; + __serverURL = [NSURL URLWithString:serverUrlString]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"jobs"]; + self.requestData.URIComponents = __pathComponents; + + [self.requestData setParameter:[self.input qcloud_modelToJSONObject] withKey:@"Request"]; + + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudPostHashProcessJobsResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/request/QCloudUpdateFileProcessQueueRequest.h b/QCloudCOSXML/Classes/CI/request/QCloudUpdateFileProcessQueueRequest.h new file mode 100644 index 0000000..d988265 --- /dev/null +++ b/QCloudCOSXML/Classes/CI/request/QCloudUpdateFileProcessQueueRequest.h @@ -0,0 +1,89 @@ +// +// QCloudUpdateFileProcessQueueRequest.h +// QCloudUpdateFileProcessQueueRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudUpdateFileProcessQueueResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 更新文件处理队列. + + ### 功能描述 + + 本接口用于更新文件处理的队列 + + 具体请查看 https://cloud.tencent.com/document/product/460/86420 + +### 示例 + + @code + + QCloudUpdateFileProcessQueueRequest * request = [QCloudUpdateFileProcessQueueRequest new]; + request.bucket = @"sample-1250000000"; + request.regionName = @"COS_REGIONNAME"; + // 设置:queueId; + request.queueId = @"123123"; + request.input = [QCloudUpdateFileProcessQueue new]; + // 队列名称,仅支持中文、英文、数字、_、-和*,长度不超过 128;是否必传:是 + request.input.Name = @"queue-file-process-1"; + // Active 表示队列内的作业会被调度执行Paused 表示队列暂停,作业不再会被调度执行,队列内的所有作业状态维持在暂停状态,已经执行中的任务不受影响;是否必传:是 + request.input.State = @"Active"; + request.input.NotifyConfig = [QCloudNotifyConfig new]; + request.input.NotifyConfig.State = @"Off"; + + [request setFinishBlock:^(QCloudUpdateFileProcessQueueResponse * outputObject, NSError *error) { + // result:QCloudUpdateFileProcessQueueResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/86420 + }]; + [[QCloudCOSXMLService defaultCOSXML] UpdateFileProcessQueue:request]; + + +*/ + +@interface QCloudUpdateFileProcessQueueRequest : QCloudBizHTTPRequest + +/// 存储桶名称 +@property (nonatomic,strong)NSString * bucket; + +@property (nonatomic,strong)NSString * queueId; + +/// 请求输入参数 +@property (nonatomic,strong)QCloudUpdateFileProcessQueue * input; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudUpdateFileProcessQueueResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/request/QCloudUpdateFileProcessQueueRequest.m b/QCloudCOSXML/Classes/CI/request/QCloudUpdateFileProcessQueueRequest.m new file mode 100644 index 0000000..874bcec --- /dev/null +++ b/QCloudCOSXML/Classes/CI/request/QCloudUpdateFileProcessQueueRequest.m @@ -0,0 +1,85 @@ +// +// QCloudUpdateFileProcessQueueRequest.m +// QCloudUpdateFileProcessQueueRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudUpdateFileProcessQueueRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudUpdateFileProcessQueueRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + QCloudURLFuseWithXMLParamters, + QCloudURLFuseContentMD5Base64StyleHeaders + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseXMLSerializerBlock, + QCloudResponseObjectSerilizerBlock([QCloudUpdateFileProcessQueueResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"put"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [self.runOnService.configuration.endpoint serverURLWithBucket:self.bucket appID:self.runOnService.configuration.appID regionName:self.regionName]; + NSString * serverUrlString = __serverURL.absoluteString; + + serverUrlString = [serverUrlString stringByReplacingOccurrencesOfString:@".cos." withString:@".ci."]; + __serverURL = [NSURL URLWithString:serverUrlString]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"file_queue"]; + if(self.queueId){ + [__pathComponents addObject:self.queueId]; + } + self.requestData.URIComponents = __pathComponents; + + [self.requestData setParameter:[self.input qcloud_modelToJSONObject] withKey:@"Request"]; + + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudUpdateFileProcessQueueResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/request/QCloudZipFilePreviewRequest.h b/QCloudCOSXML/Classes/CI/request/QCloudZipFilePreviewRequest.h new file mode 100644 index 0000000..42e61ee --- /dev/null +++ b/QCloudCOSXML/Classes/CI/request/QCloudZipFilePreviewRequest.h @@ -0,0 +1,82 @@ +// +// QCloudZipFilePreviewRequest.h +// QCloudZipFilePreviewRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudZipFilePreviewResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 压缩包预览. + + ### 功能描述 + + 该接口可以在不解压文件的情况下预览压缩包内的内容,包含文件数量、名称、文件时间等,接口为同步请求方式 + + 具体请查看 https://cloud.tencent.com/document/product/460/93030 + +### 示例 + + @code + + QCloudZipFilePreviewRequest * request = [QCloudZipFilePreviewRequest new]; + request.bucket = @"sample-1250000000"; + request.regionName = @"COS_REGIONNAME"; + + request.ObjectKey = @"test.zip"; + + [request setFinishBlock:^(QCloudZipFilePreviewResponse * outputObject, NSError *error) { + // result:QCloudZipFilePreviewResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/93030 + }]; + [[QCloudCOSXMLService defaultCOSXML] ZipFilePreview:request]; + + +*/ + +@interface QCloudZipFilePreviewRequest : QCloudBizHTTPRequest + +/// 操作类型,压缩包预览计算固定为:zippreview;是否必传:是 +@property (nonatomic,strong) NSString * ciProcess; + +/// 存储桶名称 +@property (nonatomic,strong)NSString * bucket; + +@property (nonatomic,strong)NSString * ObjectKey; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudZipFilePreviewResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/CI/request/QCloudZipFilePreviewRequest.m b/QCloudCOSXML/Classes/CI/request/QCloudZipFilePreviewRequest.m new file mode 100644 index 0000000..9f6593f --- /dev/null +++ b/QCloudCOSXML/Classes/CI/request/QCloudZipFilePreviewRequest.m @@ -0,0 +1,78 @@ +// +// QCloudZipFilePreviewRequest.m +// QCloudZipFilePreviewRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudZipFilePreviewRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudZipFilePreviewRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseXMLSerializerBlock, + QCloudResponseObjectSerilizerBlock([QCloudZipFilePreviewResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"get"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [self.runOnService.configuration.endpoint serverURLWithBucket:self.bucket appID:self.runOnService.configuration.appID regionName:self.regionName]; + + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + if(self.ObjectKey){ + [__pathComponents addObject:self.ObjectKey]; + } + self.requestData.URIComponents = __pathComponents; + + [self.requestData setQueryStringParamter:self.ciProcess?:@"zippreview" withKey:@"ci-process"]; + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudZipFilePreviewResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/Manager/QCloudCOSXMLService+Manager.m b/QCloudCOSXML/Classes/Manager/QCloudCOSXMLService+Manager.m index aeb8c9e..0f3aa0c 100644 --- a/QCloudCOSXML/Classes/Manager/QCloudCOSXMLService+Manager.m +++ b/QCloudCOSXML/Classes/Manager/QCloudCOSXMLService+Manager.m @@ -287,6 +287,31 @@ - (void)getPresignedURL:(QCloudGetPresignedURLRequest *)request { request.finishBlock(result, nil); return; } + + if (request.credential) { + QCloudAuthentationV5Creator *creator = [[QCloudAuthentationV5Creator alloc] initWithCredential:request.credential]; + QCloudSignature *signature = [creator signatureForData:(NSMutableURLRequest *)urlRequest]; + NSString *authorizatioinString = signature.signature; + if ([requestURLString hasSuffix:@"&"] || [requestURLString hasSuffix:@"?"]) { + requestURLString = [requestURLString stringByAppendingString:authorizatioinString]; + } else if([requestURLString containsString:@"?"] && ![requestURLString hasSuffix:@"&"]){ + requestURLString = [requestURLString stringByAppendingFormat:@"&%@", authorizatioinString]; + }else { + requestURLString = [requestURLString stringByAppendingFormat:@"?%@", authorizatioinString]; + } + if (signature.token) { + requestURLString = + [requestURLString stringByAppendingFormat:@"&x-cos-security-token=%@", signature.token]; + } + + QCloudGetPresignedURLResult *result = [[QCloudGetPresignedURLResult alloc] init]; + result.presienedURL = requestURLString; + if (request.finishBlock) { + request.finishBlock(result, nil); + } + return; + } + [request.signatureProvider signatureWithFields:request.signatureFields request:request urlRequest:(NSMutableURLRequest *)urlRequest diff --git a/QCloudCOSXML/Classes/Manager/request/QCloudGetPresignedURLRequest.h b/QCloudCOSXML/Classes/Manager/request/QCloudGetPresignedURLRequest.h index b06c383..f57ae7b 100644 --- a/QCloudCOSXML/Classes/Manager/request/QCloudGetPresignedURLRequest.h +++ b/QCloudCOSXML/Classes/Manager/request/QCloudGetPresignedURLRequest.h @@ -46,7 +46,7 @@ NS_ASSUME_NONNULL_BEGIN */ @interface QCloudGetPresignedURLRequest : QCloudBizHTTPRequest -@property (nonatomic, copy) NSDate *expires; + /** 填入使用预签名请求的Bucket */ diff --git a/QCloudCOSXML/Classes/MateData/QCloudCOSXMLService+MateData.h b/QCloudCOSXML/Classes/MateData/QCloudCOSXMLService+MateData.h new file mode 100644 index 0000000..82ae177 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/QCloudCOSXMLService+MateData.h @@ -0,0 +1,89 @@ +#import "QCloudCOSXMLService.h" + +#import "QCloudCreateDatasetRequest.h" +#import "QCloudCreateDatasetBindingRequest.h" +#import "QCloudCreateFileMetaIndexRequest.h" +#import "QCloudDatasetSimpleQueryRequest.h" +#import "QCloudDeleteDatasetRequest.h" +#import "QCloudDeleteDatasetBindingRequest.h" +#import "QCloudDeleteFileMetaIndexRequest.h" +#import "QCloudDescribeDatasetRequest.h" +#import "QCloudDescribeDatasetBindingRequest.h" +#import "QCloudDescribeDatasetBindingsRequest.h" +#import "QCloudDescribeDatasetsRequest.h" +#import "QCloudDescribeFileMetaIndexRequest.h" +#import "QCloudUpdateDatasetRequest.h" +#import "QCloudUpdateFileMetaIndexRequest.h" +#import "QCloudDatasetFaceSearchRequest.h" +#import "QCloudSearchImageRequest.h" + +@interface QCloudCOSXMLService (MateData) +/// 创建数据集 +/// 本接口用于创建一个数据集(Dataset)。 +-(void)CreateDataset:(QCloudCreateDatasetRequest *)request; + +/// 绑定存储桶与数据集 +/// 创建数据集(Dataset)和对象存储(COS)Bucket 的绑定关系,绑定后将使用创建数据集时所指定算子对文件进行处理。 +/// 绑定关系创建后,将对 COS 中新增的文件进行准实时的增量追踪扫描,使用创建数据集时所指定算子对文件进行处理,抽取文件元数据信息进行索引。通过此方式为文件建立索引后,您可以使用元数据查询API(例如SimpleQuery)对元数据进行查询、管理和统计。 +-(void)CreateDatasetBinding:(QCloudCreateDatasetBindingRequest *)request; + +/// 创建元数据索引 +/// 提取一个COS文件的元数据,在数据集中建立索引。会根据数据集中的算子提取不同的元数据建立索引,也支持建立自定义的元数据索引。 +-(void)CreateFileMetaIndex:(QCloudCreateFileMetaIndexRequest *)request; + +/// 简单查询 +/// 查询和统计数据集内文件,支持逻辑关系表达方式。 +-(void)DatasetSimpleQuery:(QCloudDatasetSimpleQueryRequest *)request; + +/// 删除数据集 +/// 删除一个数据集(Dataset)。 +-(void)DeleteDataset:(QCloudDeleteDatasetRequest *)request; + +/// 解绑存储桶与数据集 +/// 解绑数据集和对象存储(COS)Bucket ,解绑会导致 COS Bucket新增的变更不会同步到数据集,请谨慎操作。 +-(void)DeleteDatasetBinding:(QCloudDeleteDatasetBindingRequest *)request; + +/// 删除元数据索引 +/// 从数据集内删除一个文件的元信息。无论该文件的元信息是否在数据集内存在,均会返回删除成功。 + + +-(void)DeleteFileMetaIndex:(QCloudDeleteFileMetaIndexRequest *)request; + +/// 查询数据集 +/// 查询一个数据集(Dataset)信息。 +-(void)DescribeDataset:(QCloudDescribeDatasetRequest *)request; + +/// 查询数据集与存储桶的绑定关系 +/// 查询数据集和对象存储(COS)Bucket 绑定关系列表。 +-(void)DescribeDatasetBinding:(QCloudDescribeDatasetBindingRequest *)request; + +/// 查询绑定关系列表 +/// 查询数据集和对象存储(COS)Bucket 绑定关系列表。 +-(void)DescribeDatasetBindings:(QCloudDescribeDatasetBindingsRequest *)request; + +/// 列出数据集 +/// 获取数据集(Dataset)列表。 +-(void)DescribeDatasets:(QCloudDescribeDatasetsRequest *)request; + +/// 查询元数据索引 +/// 获取数据集内已完成索引的一个文件的元数据。 +-(void)DescribeFileMetaIndex:(QCloudDescribeFileMetaIndexRequest *)request; + +/// 更新数据集 +/// 更新一个数据集(Dataset)信息。 +-(void)UpdateDataset:(QCloudUpdateDatasetRequest *)request; + +/// 更新元数据索引 +/// 更新数据集内已索引的一个文件的部分元数据。 +/// 并非所有的元数据都允许您自定义更新,在您发起更新请求时需要填写数据集,默认会根据该数据集的算子进行元数据重新提取并更新已存在的索引,此外您也可以更新部分自定义的元数据索引,如CustomTags、CustomId等字段,具体请参考请求参数一节。 +-(void)UpdateFileMetaIndex:(QCloudUpdateFileMetaIndexRequest *)request; + +/// 人脸搜索 +/// 从数据集中搜索与指定图片最相似的前N张图片并返回人脸坐标可对数据集内文件进行一个或多个人员的人脸识别。 +-(void)DatasetFaceSearch:(QCloudDatasetFaceSearchRequest *)request; + +/// 图像检索 +/// 可通过输入自然语言或图片,基于语义对数据集内文件进行图像检索。 +-(void)SearchImage:(QCloudSearchImageRequest *)request; + +@end diff --git a/QCloudCOSXML/Classes/MateData/QCloudCOSXMLService+MateData.m b/QCloudCOSXML/Classes/MateData/QCloudCOSXMLService+MateData.m new file mode 100644 index 0000000..52e7c0c --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/QCloudCOSXMLService+MateData.m @@ -0,0 +1,69 @@ +#import "QCloudCOSXMLService+MateData.h" + +@implementation QCloudCOSXMLService (MateData) +-(void)CreateDataset:(QCloudCreateDatasetRequest *)request{ + [super performRequest:(QCloudCreateDatasetRequest *)request]; +} + +-(void)CreateDatasetBinding:(QCloudCreateDatasetBindingRequest *)request{ + [super performRequest:(QCloudCreateDatasetBindingRequest *)request]; +} + +-(void)CreateFileMetaIndex:(QCloudCreateFileMetaIndexRequest *)request{ + [super performRequest:(QCloudCreateFileMetaIndexRequest *)request]; +} + +-(void)DatasetSimpleQuery:(QCloudDatasetSimpleQueryRequest *)request{ + [super performRequest:(QCloudDatasetSimpleQueryRequest *)request]; +} + +-(void)DeleteDataset:(QCloudDeleteDatasetRequest *)request{ + [super performRequest:(QCloudDeleteDatasetRequest *)request]; +} + +-(void)DeleteDatasetBinding:(QCloudDeleteDatasetBindingRequest *)request{ + [super performRequest:(QCloudDeleteDatasetBindingRequest *)request]; +} + +-(void)DeleteFileMetaIndex:(QCloudDeleteFileMetaIndexRequest *)request{ + [super performRequest:(QCloudDeleteFileMetaIndexRequest *)request]; +} + +-(void)DescribeDataset:(QCloudDescribeDatasetRequest *)request{ + [super performRequest:(QCloudDescribeDatasetRequest *)request]; +} + +-(void)DescribeDatasetBinding:(QCloudDescribeDatasetBindingRequest *)request{ + [super performRequest:(QCloudDescribeDatasetBindingRequest *)request]; +} + +-(void)DescribeDatasetBindings:(QCloudDescribeDatasetBindingsRequest *)request{ + [super performRequest:(QCloudDescribeDatasetBindingsRequest *)request]; +} + +-(void)DescribeDatasets:(QCloudDescribeDatasetsRequest *)request{ + [super performRequest:(QCloudDescribeDatasetsRequest *)request]; +} + +-(void)DescribeFileMetaIndex:(QCloudDescribeFileMetaIndexRequest *)request{ + [super performRequest:(QCloudDescribeFileMetaIndexRequest *)request]; +} + +-(void)UpdateDataset:(QCloudUpdateDatasetRequest *)request{ + [super performRequest:(QCloudUpdateDatasetRequest *)request]; +} + +-(void)UpdateFileMetaIndex:(QCloudUpdateFileMetaIndexRequest *)request{ + [super performRequest:(QCloudUpdateFileMetaIndexRequest *)request]; +} + +-(void)DatasetFaceSearch:(QCloudDatasetFaceSearchRequest *)request{ + [super performRequest:(QCloudDatasetFaceSearchRequest *)request]; +} + +-(void)SearchImage:(QCloudSearchImageRequest *)request{ + [super performRequest:(QCloudSearchImageRequest *)request]; +} + + +@end diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudCommonModel.h b/QCloudCOSXML/Classes/MateData/model/QCloudCommonModel.h new file mode 100644 index 0000000..fd382ca --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudCommonModel.h @@ -0,0 +1,406 @@ +// +// QCloudCommonModel.h +// QCloudCommonModel +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import + + +NS_ASSUME_NONNULL_BEGIN + +@class QCloudAggregations; +@class QCloudAggregationsResult; +@class QCloudBinding; +@class QCloudDataset; +@class QCloudDatasets; +@class QCloudFile; +@class QCloudFileResult; +@class QCloudFilesDetail; +@class QCloudGroups; +@class QCloudImageResult; +@class QCloudObject; +@class QCloudPersons; +@class QCloudQuery; +@class QCloudSubQueries; +@class QCloudUpdateMetaFile; +@interface QCloudAggregations : NSObject + +/// 聚合字段的操作符。枚举值:min:最小值。max:最大值。average:平均数sum:求和。count:计数。distinct:去重计数。group:分组计数,按照分组计数结果从高到低排序。 ;是否必传:否 +@property (nonatomic,strong) NSString * Operation; + +/// 字段名称。关于支持的字段,请参考字段和操作符的支持列表。;是否必传:否 +@property (nonatomic,strong) NSString * Field; + +@end + +@interface QCloudAggregationsResult : NSObject + +/// 聚合字段的聚合操作符。 ;是否必传:否 +@property (nonatomic,strong) NSString * Operation; + +/// 聚合的统计结果。 ;是否必传:否 +@property (nonatomic,assign) CGFloat Value; + +/// 分组聚合的结果列表。仅在请求的Aggregations中存在group类型的Operation时才会返回。;是否必传:否 +@property (nonatomic,strong)NSArray * Groups; + +/// 聚合字段名称。;是否必传:否 +@property (nonatomic,strong) NSString * Field; + +@end + +@interface QCloudBinding : NSObject + +/// 资源标识字段,表示需要与数据集绑定的资源,当前仅支持COS存储桶,字段规则:cos://,其中BucketName表示COS存储桶名称,例如:cos://examplebucket-1250000000 ;是否必传:否 +@property (nonatomic,strong) NSString * URI; + +/// 数据集和 COS Bucket绑定关系的状态。取值范围如下:Running:绑定关系运行中。 ;是否必传:否 +@property (nonatomic,strong) NSString * State; + +/// 数据集和 COS Bucket绑定关系创建时间的时间戳,格式为RFC3339Nano。 ;是否必传:否 +@property (nonatomic,strong) NSString * CreateTime; + +/// 数据集和 COS Bucket的绑定关系修改时间的时间戳,格式为RFC3339Nano。创建绑定关系后,如果未暂停或者未重启过绑定关系,则绑定关系修改时间的时间戳和绑定关系创建时间的时间戳相同。 ;是否必传:否 +@property (nonatomic,strong) NSString * UpdateTime; + +/// 数据集名称。;是否必传:否 +@property (nonatomic,strong) NSString * DatasetName; + +@end + +@interface QCloudDataset : NSObject + +/// 模板ID。 ;是否必传:否 +@property (nonatomic,strong) NSString * TemplateId; + +/// 数据集描述信息 ;是否必传:否 +@property (nonatomic,strong) NSString * Description; + +/// 数据集创建时间的时间戳,格式为RFC3339Nano。;是否必传:否 +@property (nonatomic,strong) NSString * CreateTime; + +/// 数据集修改时间的时间戳,格式为RFC3339Nano。创建数据集后,如果未更新过数据集,则数据集修改时间的时间戳和数据集创建时间的时间戳相同 ;是否必传:否 +@property (nonatomic,strong) NSString * UpdateTime; + +/// 数据集当前绑定的COS Bucket数量 ;是否必传:否 +@property (nonatomic,assign) NSInteger BindCount; + +/// 数据集当前文件数量 ;是否必传:否 +@property (nonatomic,assign) NSInteger FileCount; + +/// 数据集中当前文件总大小,单位为字节 ;是否必传:否 +@property (nonatomic,assign) NSInteger TotalFileSize; + +/// 数据集名称;是否必传:否 +@property (nonatomic,strong) NSString * DatasetName; + +@end + +@interface QCloudDatasets : NSObject + +/// 模板ID。 ;是否必传:否 +@property (nonatomic,strong) NSString * TemplateId; + +/// 数据集描述信息 ;是否必传:否 +@property (nonatomic,strong) NSString * Description; + +/// 数据集创建时间的时间戳,格式为RFC3339Nano。;是否必传:否 +@property (nonatomic,strong) NSString * CreateTime; + +/// 数据集修改时间的时间戳,格式为RFC3339Nano。创建数据集后,如果未更新过数据集,则数据集修改时间的时间戳和数据集创建时间的时间戳相同 ;是否必传:否 +@property (nonatomic,strong) NSString * UpdateTime; + +/// 数据集当前绑定的COS Bucket数量 ;是否必传:否 +@property (nonatomic,assign) NSInteger BindCount; + +/// 数据集当前文件数量 ;是否必传:否 +@property (nonatomic,assign) NSInteger FileCount; + +/// 数据集中当前文件总大小,单位为字节 ;是否必传:否 +@property (nonatomic,assign) NSInteger TotalFileSize; + +/// 数据集名称;是否必传:否 +@property (nonatomic,strong) NSString * DatasetName; + +@end + +@interface QCloudFile : NSObject + +/// 自定义ID。该文件索引到数据集后,作为该行元数据的属性存储,用于和您的业务系统进行关联、对应。您可以根据业务需求传入该值,例如将某个URI关联到您系统内的某个ID。推荐传入全局唯一的值。在查询时,该字段支持前缀查询和排序,详情请见[字段和操作符的支持列表](https://cloud.tencent.com/document/product/460/106154)。 ;是否必传:否 +@property (nonatomic,strong) NSString * CustomId; + +/// 自定义标签。您可以根据业务需要自定义添加标签键值对信息,用于在查询时可以据此为筛选项进行检索,详情请见[字段和操作符的支持列表](https://cloud.tencent.com/document/product/460/106154)。 ;是否必传:否 +@property (nonatomic,strong) NSDictionary * CustomLabels; + +/// 自定义标签键 ;是否必传:否 +@property (nonatomic,strong) NSString * Key; + +/// 自定义标签值 ;是否必传:否 +@property (nonatomic,strong) NSString * Value; + +/// 可选项,文件媒体类型,枚举值: image:图片。 other:其他。 document:文档。 archive:压缩包。 video:视频。 audio:音频。 ;是否必传:否 +@property (nonatomic,strong) NSString * MediaType; + +/// 可选项,文件内容类型(MIME Type),如image/jpeg。 ;是否必传:否 +@property (nonatomic,strong) NSString * ContentType; + +/// 资源标识字段,表示需要建立索引的文件地址,当前仅支持COS上的文件,字段规则:cos:///,其中BucketName表示COS存储桶名称,ObjectKey表示文件完整路径,例如:cos://examplebucket-1250000000/test1/img.jpg。 注意: 1、仅支持本账号内的COS文件 2、不支持HTTP开头的地址;是否必传:是 +@property (nonatomic,strong) NSString * URI; + +/// 输入图片中检索的人脸数量,默认值为20,最大值为20。(仅当数据集模板 ID 为 Official:FaceSearch 有效)。;是否必传:否 +@property (nonatomic,assign) NSInteger MaxFaceNum; + +/// 自定义人物属性(仅当数据集模板 ID 为 Official:FaceSearch 有效)。;是否必传:否 +@property (nonatomic,strong)NSArray * Persons; + +@end + +@interface QCloudFileResult : NSObject + +/// 对象唯一ID。 ;是否必传:否 +@property (nonatomic,strong) NSString * ObjectId; + +/// 元数据创建时间的时间戳,格式为RFC3339Nano ;是否必传:否 +@property (nonatomic,strong) NSString * CreateTime; + +/// 元数据修改时间的时间戳,格式为RFC3339Nano创建元数据后,如果未更新过元数据,则元数据修改时间的时间戳和元数据创建时间的时间戳相同 ;是否必传:否 +@property (nonatomic,strong) NSString * UpdateTime; + +/// 资源标识字段,表示需要建立索引的文件地址 ;是否必传:否 +@property (nonatomic,strong) NSString * URI; + +/// 文件路径 ;是否必传:否 +@property (nonatomic,strong) NSString * Filename; + +/// 文件媒体类型。 枚举值:image:图片。other:其他。document:文档。archive:压缩包。audio:音频。video:视频。;是否必传:否 +@property (nonatomic,strong) NSString * MediaType; + +/// 文件内容类型(MIME Type)。;是否必传:否 +@property (nonatomic,strong) NSString * ContentType; + +/// 文件存储空间类型。;是否必传:否 +@property (nonatomic,strong) NSString * COSStorageClass; + +/// 文件CRC64值。 ;是否必传:否 +@property (nonatomic,strong) NSString * COSCRC64; + +/// 文件大小,单位为字节。 ;是否必传:否 +@property (nonatomic,assign) NSInteger Size; + +/// 指定Object被下载时网页的缓存行为。该字段需要设置COS Object HTTP属性Cache-Control。 ;是否必传:否 +@property (nonatomic,strong) NSString * CacheControl; + +/// 指定Object被下载时的名称。需要设置COS Object HTTP属性Content-Disposition。 ;是否必传:否 +@property (nonatomic,strong) NSString * ContentDisposition; + +/// 指定该Object被下载时的内容编码格式。需要设置COS Object HTTP属性Content-Encoding。 ;是否必传:否 +@property (nonatomic,strong) NSString * ContentEncoding; + +/// Object内容使用的语言。需要设置COS Object HTTP属性Content-Language。 ;是否必传:否 +@property (nonatomic,strong) NSString * ContentLanguage; + +/// 加密算法,需要设置x-cos-server-side-encryption。 ;是否必传:否 +@property (nonatomic,strong) NSString * ServerSideEncryption; + +/// Object生成时会创建相应的ETag ,ETag用于标识一个Object的内容。 ;是否必传:否 +@property (nonatomic,strong) NSString * ETag; + +/// 文件最近一次修改时间的时间戳, 格式为RFC3339Nano。;是否必传:否 +@property (nonatomic,strong) NSString * FileModifiedTime; + +/// 该文件的自定义ID。该文件索引到数据集后,作为该行元数据的属性存储,用于和您的业务系统进行关联、对应。您可以根据业务需求传入该值,例如将某个URI关联到您系统内的某个ID。推荐传入全局唯一的值。;是否必传:否 +@property (nonatomic,strong) NSString * CustomId; + +/// 文件自定义标签列表。储存您业务自定义的键名、键值对信息,用于在查询时可以据此为筛选项进行检索。;是否必传:否 +@property (nonatomic,strong) NSDictionary * CustomLabels; + +/// cos自定义头部。储存您业务在cos object上的键名、键值对信息,用于在查询时可以据此为筛选项进行检索。;是否必传:否 +@property (nonatomic,strong) NSDictionary * COSUserMeta; + +/// 文件访问权限属性。 ;是否必传:否 +@property (nonatomic,strong) NSString * ObjectACL; + +/// cos自定义标签。储存您业务在cos object上的自定义标签的键名、键值对信息,用于在查询时可以据此为筛选项进行检索。;是否必传:否 +@property (nonatomic,strong) NSDictionary * COSTagging; + +/// cos自定义标签的数量。 ;是否必传:否 +@property (nonatomic,assign) NSInteger COSTaggingCount; + +/// 数据集名称。;是否必传:否 +@property (nonatomic,strong) NSString * DatasetName; + +@end + +@interface QCloudFilesDetail : NSObject + +/// 元数据创建时间的时间戳,格式为RFC3339Nano ;是否必传:否 +@property (nonatomic,strong) NSString * CreateTime; + +/// 元数据修改时间的时间戳,格式为RFC3339Nano创建元数据后,如果未更新过元数据,则元数据修改时间的时间戳和元数据创建时间的时间戳相同 ;是否必传:否 +@property (nonatomic,strong) NSString * UpdateTime; + +/// 资源标识字段,表示需要建立索引的文件地址 ;是否必传:否 +@property (nonatomic,strong) NSString * URI; + +/// 文件路径 ;是否必传:否 +@property (nonatomic,strong) NSString * Filename; + +/// 文件媒体类型。 枚举值:image:图片。other:其他。document:文档。archive:压缩包。audio:音频。video:视频。;是否必传:否 +@property (nonatomic,strong) NSString * MediaType; + +/// 文件内容类型(MIME Type)。;是否必传:否 +@property (nonatomic,strong) NSString * ContentType; + +/// 文件存储空间类型。;是否必传:否 +@property (nonatomic,strong) NSString * COSStorageClass; + +/// 文件CRC64值。 ;是否必传:否 +@property (nonatomic,strong) NSString * COSCRC64; + +/// 对象ACL。 ;是否必传:否 +@property (nonatomic,strong) NSString * ObjectACL; + +/// 文件大小,单位为字节。 ;是否必传:否 +@property (nonatomic,assign) NSInteger Size; + +/// 指定Object被下载时网页的缓存行为。 ;是否必传:否 +@property (nonatomic,strong) NSString * CacheControl; + +/// Object生成时会创建相应的ETag ,ETag用于标识一个Object的内容。 ;是否必传:否 +@property (nonatomic,strong) NSString * ETag; + +/// 文件最近一次修改时间的时间戳, 格式为RFC3339Nano。;是否必传:否 +@property (nonatomic,strong) NSString * FileModifiedTime; + +/// 该文件的自定义ID。该文件索引到数据集后,作为该行元数据的属性存储,用于和您的业务系统进行关联、对应。您可以根据业务需求传入该值,例如将某个URI关联到您系统内的某个ID。推荐传入全局唯一的值。;是否必传:否 +@property (nonatomic,strong) NSString * CustomId; + +/// 文件自定义标签列表。储存您业务自定义的键名、键值对信息,用于在查询时可以据此为筛选项进行检索。;是否必传:否 +@property (nonatomic,strong) NSDictionary * CustomLabels; + +/// 数据集名称。;是否必传:否 +@property (nonatomic,strong) NSString * DatasetName; + +@end + +@interface QCloudGroups : NSObject + +/// 分组聚合的总个数。 ;是否必传:否 +@property (nonatomic,assign) NSInteger Count; + +/// 分组聚合的值。;是否必传:否 +@property (nonatomic,strong) NSString * Value; + +@end + +@interface QCloudImageResult : NSObject + +/// 资源标识字段,表示需要建立索引的文件地址。;是否必传:否 +@property (nonatomic,strong) NSString * URI; + +/// 相关图片匹配得分。;是否必传:否 +@property (nonatomic,assign) NSInteger Score; + +@end + +@interface QCloudObject : NSObject + +/// 键;是否必传:否 +@property (nonatomic,strong) NSString * key; + +/// 值;是否必传:否 +@property (nonatomic,strong) NSString * value; + +@end + +@interface QCloudPersons : NSObject + +/// 自定义人物 ID。;是否必传:否 +@property (nonatomic,strong) NSString * PersonId; + +@end + +@interface QCloudQuery : NSObject + +/// 操作运算符。枚举值: not:逻辑非。 or:逻辑或。 and:逻辑与。 lt:小于。 lte:小于等于。 gt:大于。 gte:大于等于。 eq:等于。 exist:存在性查询。 prefix:前缀查询。 match-phrase:字符串匹配查询。 nested:字段为数组时,其中同一对象内逻辑条件查询。;是否必传:是 +@property (nonatomic,strong) NSString * Operation; + +/// 子查询的结构体。 只有当Operations为逻辑运算符(and、or、not或nested)时,才能设置子查询条件。 在逻辑运算符为and/or/not时,其SubQueries内描述的所有条件需符合父级设置的and/or/not逻辑关系。 在逻辑运算符为nested时,其父级的Field必须为一个数组类的字段(如:Labels)。 子查询条件SubQueries组的Operation必须为and/or/not中的一个或多个,其Field必须为父级Field的子属性。;是否必传:否 +@property (nonatomic,strong)NSArray * SubQueries; + +/// 字段名称。关于支持的字段,请参考[字段和操作符的支持列表](https://cloud.tencent.com/document/product/460/106154)。;是否必传:否 +@property (nonatomic,strong) NSString * Field; + +/// 查询的字段值。当Operations为逻辑运算符(and、or、not或nested)时,该字段无效。;是否必传:否 +@property (nonatomic,strong) NSString * Value; + +@end + +@interface QCloudSubQueries : NSObject + +/// 查询的字段值。当Operations为逻辑运算符(and、or、not或nested)时,该字段无效。;是否必传:否 +@property (nonatomic,strong) NSString * Value; + +/// 操作运算符。枚举值:not:逻辑非。or:逻辑或。and:逻辑与。lt:小于。lte:小于等于。gt:大于。gte:大于等于。eq:等于。exist:存在性查询。prefix:前缀查询。match-phrase:字符串匹配查询。nested:字段为数组时,其中同一对象内逻辑条件查询。 ;是否必传:是 +@property (nonatomic,strong) NSString * Operation; + +/// 字段名称。关于支持的字段,请参考字段和操作符的支持列表。;是否必传:否 +@property (nonatomic,strong) NSString * Field; + +@end + +@interface QCloudUpdateMetaFile : NSObject + +/// 自定义ID。该文件索引到数据集后,作为该行元数据的属性存储,用于和您的业务系统进行关联、对应。您可以根据业务需求传入该值,例如将某个URI关联到您系统内的某个ID。推荐传入全局唯一的值。在查询时,该字段支持前缀查询和排序,详情请见[字段和操作符的支持列表](https://cloud.tencent.com/document/product/460/106154)。 ;是否必传:否 +@property (nonatomic,strong) NSString * CustomId; + +/// 自定义标签。您可以根据业务需要自定义添加标签键值对信息,用于在查询时可以据此为筛选项进行检索,详情请见[字段和操作符的支持列表](https://cloud.tencent.com/document/product/460/106154)。 ;是否必传:否 +@property (nonatomic,strong) NSDictionary * CustomLabels; + +/// 自定义标签键 ;是否必传:否 +@property (nonatomic,strong) NSString * Key; + +/// 自定义标签值 ;是否必传:否 +@property (nonatomic,strong) NSString * Value; + +/// 可选项,文件媒体类型,枚举值: image:图片。 other:其他。 document:文档。 archive:压缩包。 video:视频。 audio:音频。 ;是否必传:否 +@property (nonatomic,strong) NSString * MediaType; + +/// 可选项,文件内容类型(MIME Type),如image/jpeg。 ;是否必传:否 +@property (nonatomic,strong) NSString * ContentType; + +/// 资源标识字段,表示需要建立索引的文件地址,当前仅支持COS上的文件,字段规则:cos:///,其中BucketName表示COS存储桶名称,ObjectKey表示文件完整路径,例如:cos://examplebucket-1250000000/test1/img.jpg。 注意: 1、仅支持本账号内的COS文件 2、不支持HTTP开头的地址;是否必传:是 +@property (nonatomic,strong) NSString * URI; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudCommonModel.m b/QCloudCOSXML/Classes/MateData/model/QCloudCommonModel.m new file mode 100644 index 0000000..0b85d1d --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudCommonModel.m @@ -0,0 +1,159 @@ +// +// QCloudCommonModel.m +// QCloudCommonModel +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudCommonModel.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudAggregations + +@end + +@implementation QCloudAggregationsResult + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Groups" : [QCloudGroups class], + }; +} + +- (NSDictionary *)modelCustomWillTransformFromDictionary:(NSDictionary *)dic { + + if (!dic) {return dic;} + + if (![dic isKindOfClass:[NSDictionary class]]) {return nil;} + + if (dic[@"Groups"] && [dic[@"Groups"] isKindOfClass:[NSDictionary class]]){ + NSMutableDictionary * mdic = [NSMutableDictionary dictionaryWithDictionary:dic]; + [mdic setValue:@[dic[@"Groups"]] forKey:@"Groups"]; + dic = mdic.copy; + } + return dic; +} + +@end + +@implementation QCloudBinding + +@end + +@implementation QCloudDataset + +@end + +@implementation QCloudDatasets + +@end + +@implementation QCloudFile + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Persons" : [QCloudPersons class], + }; +} + +- (NSDictionary *)modelCustomWillTransformFromDictionary:(NSDictionary *)dic { + + if (!dic) {return dic;} + + if (![dic isKindOfClass:[NSDictionary class]]) {return nil;} + + if (dic[@"Persons"] && [dic[@"Persons"] isKindOfClass:[NSDictionary class]]){ + NSMutableDictionary * mdic = [NSMutableDictionary dictionaryWithDictionary:dic]; + [mdic setValue:@[dic[@"Persons"]] forKey:@"Persons"]; + dic = mdic.copy; + } + return dic; +} + +@end + +@implementation QCloudFileResult + +@end + +@implementation QCloudFilesDetail + +@end + +@implementation QCloudGroups + +@end + +@implementation QCloudImageResult + +@end + +@implementation QCloudObject + +@end + +@implementation QCloudPersons + +@end + +@implementation QCloudQuery + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"SubQueries" : [QCloudSubQueries class], + }; +} + +- (NSDictionary *)modelCustomWillTransformFromDictionary:(NSDictionary *)dic { + + if (!dic) {return dic;} + + if (![dic isKindOfClass:[NSDictionary class]]) {return nil;} + + if (dic[@"SubQueries"] && [dic[@"SubQueries"] isKindOfClass:[NSDictionary class]]){ + NSMutableDictionary * mdic = [NSMutableDictionary dictionaryWithDictionary:dic]; + [mdic setValue:@[dic[@"SubQueries"]] forKey:@"SubQueries"]; + dic = mdic.copy; + } + return dic; +} + +@end + +@implementation QCloudSubQueries + +@end + +@implementation QCloudUpdateMetaFile + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudCreateDatasetBindingResponse.h b/QCloudCOSXML/Classes/MateData/model/QCloudCreateDatasetBindingResponse.h new file mode 100644 index 0000000..1d0a04c --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudCreateDatasetBindingResponse.h @@ -0,0 +1,60 @@ +// +// QCloudCreateDatasetBindingResponse.h +// QCloudCreateDatasetBindingResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@interface QCloudCreateDatasetBindingResponse : NSObject + +/// 请求ID +@property (nonatomic,strong) NSString * RequestId; + +/// 绑定信息 +@property (nonatomic,strong) QCloudBinding * Binding; + +@end + +@interface QCloudCreateDatasetBinding : NSObject + +/// 数据集名称,同一个账户下唯一;是否必传:是 +@property (nonatomic,strong) NSString * DatasetName; + +/// 资源标识字段,表示需要与数据集绑定的资源,当前仅支持COS存储桶,字段规则:cos://,其中BucketName表示COS存储桶名称,例如:cos://examplebucket-1250000000;是否必传:是 +@property (nonatomic,strong) NSString * URI; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudCreateDatasetBindingResponse.m b/QCloudCOSXML/Classes/MateData/model/QCloudCreateDatasetBindingResponse.m new file mode 100644 index 0000000..33d8669 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudCreateDatasetBindingResponse.m @@ -0,0 +1,53 @@ +// +// QCloudCreateDatasetBindingResponse.m +// QCloudCreateDatasetBindingResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudCreateDatasetBindingResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudCreateDatasetBindingResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Binding" : [QCloudBinding class], + }; +} + +@end + +@implementation QCloudCreateDatasetBinding + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudCreateDatasetResponse.h b/QCloudCOSXML/Classes/MateData/model/QCloudCreateDatasetResponse.h new file mode 100644 index 0000000..a0efaeb --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudCreateDatasetResponse.h @@ -0,0 +1,63 @@ +// +// QCloudCreateDatasetResponse.h +// QCloudCreateDatasetResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@interface QCloudCreateDatasetResponse : NSObject + +/// 请求ID +@property (nonatomic,strong) NSString * RequestId; + +/// 数据集信息 +@property (nonatomic,strong) QCloudDataset * Dataset; + +@end + +@interface QCloudCreateDataset : NSObject + +/// 数据集名称,同一个账户下唯一。命名规则如下: 长度为1~32字符。 只能包含小写英文字母,数字,短划线(-)。 必须以英文字母和数字开头。;是否必传:是 +@property (nonatomic,strong) NSString * DatasetName; + +/// 数据集描述信息。长度为1~256个英文或中文字符,默认值为空。;是否必传:否 +@property (nonatomic,strong) NSString * Description; + +/// 与数据集关联的检索模板,在建立元数据索引时,后端将根据检索模板来决定采集文件的哪些元数据。每个检索模板都包含若干个算子,不同的算子表示不同的处理能力,更多信息请参见 [检索模板与算子](https://cloud.tencent.com/document/product/460/106018)。 默认值为空,即不关联检索模板,不进行任何元数据的采集。;是否必传:否 +@property (nonatomic,strong) NSString * TemplateId; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudCreateDatasetResponse.m b/QCloudCOSXML/Classes/MateData/model/QCloudCreateDatasetResponse.m new file mode 100644 index 0000000..da02754 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudCreateDatasetResponse.m @@ -0,0 +1,53 @@ +// +// QCloudCreateDatasetResponse.m +// QCloudCreateDatasetResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudCreateDatasetResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudCreateDatasetResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Dataset" : [QCloudDataset class], + }; +} + +@end + +@implementation QCloudCreateDataset + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudCreateFileMetaIndexResponse.h b/QCloudCOSXML/Classes/MateData/model/QCloudCreateFileMetaIndexResponse.h new file mode 100644 index 0000000..11ec53c --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudCreateFileMetaIndexResponse.h @@ -0,0 +1,60 @@ +// +// QCloudCreateFileMetaIndexResponse.h +// QCloudCreateFileMetaIndexResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@interface QCloudCreateFileMetaIndexResponse : NSObject + +/// 请求ID +@property (nonatomic,strong) NSString * RequestId; + +/// 创建元数据索引的任务ID +@property (nonatomic,strong) NSString * EventId; + +@end + +@interface QCloudCreateFileMetaIndex : NSObject + +/// 数据集名称,同一个账户下唯一。;是否必传:是 +@property (nonatomic,strong) NSString * DatasetName; + +/// 用于建立索引的文件信息。;是否必传:是 +@property (nonatomic,strong) QCloudFile * File; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudCreateFileMetaIndexResponse.m b/QCloudCOSXML/Classes/MateData/model/QCloudCreateFileMetaIndexResponse.m new file mode 100644 index 0000000..35f16e5 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudCreateFileMetaIndexResponse.m @@ -0,0 +1,53 @@ +// +// QCloudCreateFileMetaIndexResponse.m +// QCloudCreateFileMetaIndexResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudCreateFileMetaIndexResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudCreateFileMetaIndexResponse + +@end + +@implementation QCloudCreateFileMetaIndex + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"File" : [QCloudFile class], + }; +} + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudDatasetFaceSearchResponse.h b/QCloudCOSXML/Classes/MateData/model/QCloudDatasetFaceSearchResponse.h new file mode 100644 index 0000000..88e8498 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudDatasetFaceSearchResponse.h @@ -0,0 +1,117 @@ +// +// QCloudDatasetFaceSearchResponse.h +// QCloudDatasetFaceSearchResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@class QCloudFaceResult; +@class QCloudFaceBoundary; +@class QCloudFaceInfos; +@interface QCloudDatasetFaceSearchResponse : NSObject + +/// 人脸检索识别结果信息列表。 +@property (nonatomic,strong)NSArray * FaceResult; + +/// 请求 ID。 +@property (nonatomic,strong) NSString * RequestId; + +@end + +@interface QCloudFaceResult : NSObject + +/// 相关人脸信息列表。;是否必传:否 +@property (nonatomic,strong)NSArray * FaceInfos; + +/// 输入图片的人脸框位置。;是否必传:否 +@property (nonatomic,strong) QCloudFaceBoundary * InputFaceBoundary; + +@end + +@interface QCloudFaceBoundary : NSObject + +/// 人脸高度。;是否必传:否 +@property (nonatomic,assign) NSInteger Height; + +/// 人脸宽度。;是否必传:否 +@property (nonatomic,assign) NSInteger Width; + +/// 人脸框左上角横坐标。;是否必传:否 +@property (nonatomic,assign) NSInteger Left; + +/// 人脸框左上角纵坐标。;是否必传:否 +@property (nonatomic,assign) NSInteger Top; + +@end + +@interface QCloudFaceInfos : NSObject + +/// 自定义人物ID。;是否必传:否 +@property (nonatomic,strong) NSString * PersonId; + +/// 相关人脸框位置。;是否必传:否 +@property (nonatomic,strong) QCloudFaceBoundary * FaceBoundary; + +/// 人脸ID。;是否必传:否 +@property (nonatomic,strong) NSString * FaceId; + +/// 相关人脸匹配得分。;是否必传:否 +@property (nonatomic,assign) NSInteger Score; + +/// 资源标识字段,表示需要建立索引的文件地址。;是否必传:否 +@property (nonatomic,strong) NSString * URI; + +@end + +@interface QCloudDatasetFaceSearch : NSObject + +/// 数据集名称,同一个账户下唯一。;是否必传:是 +@property (nonatomic,strong) NSString * DatasetName; + +/// 资源标识字段,表示需要建立索引的文件地址。;是否必传:是 +@property (nonatomic,strong) NSString * URI; + +/// 输入图片中检索的人脸数量,默认值为1(传0或不传采用默认值),最大值为10。;是否必传:否 +@property (nonatomic,assign) NSInteger MaxFaceNum; + +/// 检索的每张人脸返回相关人脸数量,默认值为10,最大值为100。;是否必传:否 +@property (nonatomic,assign) NSInteger Limit; + +/// 限制返回人脸的最低相关度分数,只有超过 MatchThreshold 值的人脸才会返回。默认值为0,推荐值为80。 例如:设置 MatchThreshold 的值为80,则检索结果中仅会返回相关度分数大于等于80分的人脸。;是否必传:否 +@property (nonatomic,assign) NSInteger MatchThreshold; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudDatasetFaceSearchResponse.m b/QCloudCOSXML/Classes/MateData/model/QCloudDatasetFaceSearchResponse.m new file mode 100644 index 0000000..afb6aa6 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudDatasetFaceSearchResponse.m @@ -0,0 +1,106 @@ +// +// QCloudDatasetFaceSearchResponse.m +// QCloudDatasetFaceSearchResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDatasetFaceSearchResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudDatasetFaceSearchResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"FaceResult" : [QCloudFaceResult class], + }; +} + +- (NSDictionary *)modelCustomWillTransformFromDictionary:(NSDictionary *)dic { + + if (!dic) {return dic;} + + if (![dic isKindOfClass:[NSDictionary class]]) {return nil;} + + if (dic[@"FaceResult"] && [dic[@"FaceResult"] isKindOfClass:[NSDictionary class]]){ + NSMutableDictionary * mdic = [NSMutableDictionary dictionaryWithDictionary:dic]; + [mdic setValue:@[dic[@"FaceResult"]] forKey:@"FaceResult"]; + dic = mdic.copy; + } + return dic; +} + +@end + +@implementation QCloudFaceResult + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"FaceInfos" : [QCloudFaceInfos class], + @"InputFaceBoundary" : [QCloudFaceBoundary class], + }; +} + +- (NSDictionary *)modelCustomWillTransformFromDictionary:(NSDictionary *)dic { + + if (!dic) {return dic;} + + if (![dic isKindOfClass:[NSDictionary class]]) {return nil;} + + if (dic[@"FaceInfos"] && [dic[@"FaceInfos"] isKindOfClass:[NSDictionary class]]){ + NSMutableDictionary * mdic = [NSMutableDictionary dictionaryWithDictionary:dic]; + [mdic setValue:@[dic[@"FaceInfos"]] forKey:@"FaceInfos"]; + dic = mdic.copy; + } + return dic; +} + +@end + +@implementation QCloudFaceBoundary + +@end + +@implementation QCloudFaceInfos + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"FaceBoundary" : [QCloudFaceBoundary class], + }; +} + +@end + +@implementation QCloudDatasetFaceSearch + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudDatasetSimpleQueryResponse.h b/QCloudCOSXML/Classes/MateData/model/QCloudDatasetSimpleQueryResponse.h new file mode 100644 index 0000000..dd03879 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudDatasetSimpleQueryResponse.h @@ -0,0 +1,84 @@ +// +// QCloudDatasetSimpleQueryResponse.h +// QCloudDatasetSimpleQueryResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@interface QCloudDatasetSimpleQueryResponse : NSObject + +/// 请求ID +@property (nonatomic,strong) NSString * RequestId; + +/// 文件信息列表。仅在请求的Aggregations为空时返回。 +@property (nonatomic,strong)NSArray * Files; + +/// 聚合字段信息列表。仅在请求的Aggregations不为空时返回。 +@property (nonatomic,strong)NSArray * Aggregations; + +/// 翻页标记。当文件总数大于设置的MaxResults时,用于翻页的Token。符合条件的文件信息未全部返回时,此参数才有值。下一次列出文件信息时将此值作为NextToken传入,将后续的文件信息返回。 +@property (nonatomic,strong) NSString * NextToken; + +@end + +@interface QCloudDatasetSimpleQuery : NSObject + +/// 数据集名称,同一个账户下唯一。;是否必传:是 +@property (nonatomic,strong) NSString * DatasetName; + +/// 简单查询参数条件,可自嵌套。;是否必传:否 +@property (nonatomic,strong) QCloudQuery * Query; + +/// 返回文件元数据的最大个数,取值范围为0200。 使用聚合参数时,该值表示返回分组的最大个数,取值范围为02000。 不设置此参数或者设置为0时,则取默认值100。;是否必传:否 +@property (nonatomic,assign) NSInteger MaxResults; + +/// 当绑定关系总数大于设置的MaxResults时,用于翻页的token。从NextToken开始按字典序返回绑定关系信息列表。第一次调用此接口时,设置为空。;是否必传:否 +@property (nonatomic,strong) NSString * NextToken; + +/// 排序字段列表。请参考[字段和操作符的支持列表](https://cloud.tencent.com/document/product/460/106154)。 多个排序字段可使用半角逗号(,)分隔,例如:Size,Filename。 最多可设置5个排序字段。 排序字段顺序即为排序优先级顺序。;是否必传:否 +@property (nonatomic,strong) NSString * Sort; + +/// 排序字段的排序方式。取值如下: asc:升序; desc(默认):降序。 多个排序方式可使用半角逗号(,)分隔,例如:asc,desc。 排序方式不可多于排序字段,即参数Order的元素数量需小于等于参数Sort的元素数量。例如Sort取值为Size,Filename时,Order可取值为asc,desc或asc。 排序方式少于排序字段时,未排序的字段默认取值asc。例如Sort取值为Size,Filename,Order取值为asc时,Filename默认排序方式为asc,即升序排列;是否必传:否 +@property (nonatomic,strong) NSString * Order; + +/// 聚合字段信息列表。 当您使用聚合查询时,仅返回聚合结果,不再返回匹配到的元信息列表。;是否必传:否 +@property (nonatomic,strong)NSArray * Aggregations; + +/// 仅返回特定字段的值,而不是全部已有的元信息字段。可用于降低返回的结构体大小。不填或留空则返回所有字段。;是否必传:否 +@property (nonatomic,strong) NSString * WithFields; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudDatasetSimpleQueryResponse.m b/QCloudCOSXML/Classes/MateData/model/QCloudDatasetSimpleQueryResponse.m new file mode 100644 index 0000000..0036a2b --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudDatasetSimpleQueryResponse.m @@ -0,0 +1,80 @@ +// +// QCloudDatasetSimpleQueryResponse.m +// QCloudDatasetSimpleQueryResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDatasetSimpleQueryResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudDatasetSimpleQueryResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Files" : [QCloudFileResult class], + @"Aggregations" : [QCloudAggregationsResult class], + }; +} + +- (NSDictionary *)modelCustomWillTransformFromDictionary:(NSDictionary *)dic { + + if (!dic) {return dic;} + + if (![dic isKindOfClass:[NSDictionary class]]) {return nil;} + + if (dic[@"Files"] && [dic[@"Files"] isKindOfClass:[NSDictionary class]]){ + NSMutableDictionary * mdic = [NSMutableDictionary dictionaryWithDictionary:dic]; + [mdic setValue:@[dic[@"Files"]] forKey:@"Files"]; + dic = mdic.copy; + } + if (dic[@"Aggregations"] && [dic[@"Aggregations"] isKindOfClass:[NSDictionary class]]){ + NSMutableDictionary * mdic = [NSMutableDictionary dictionaryWithDictionary:dic]; + [mdic setValue:@[dic[@"Aggregations"]] forKey:@"Aggregations"]; + dic = mdic.copy; + } + return dic; +} + +@end + +@implementation QCloudDatasetSimpleQuery + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Query" : [QCloudQuery class], + @"Aggregations" : [QCloudAggregations class], + }; +} + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudDeleteDatasetBindingResponse.h b/QCloudCOSXML/Classes/MateData/model/QCloudDeleteDatasetBindingResponse.h new file mode 100644 index 0000000..cad3e7a --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudDeleteDatasetBindingResponse.h @@ -0,0 +1,57 @@ +// +// QCloudDeleteDatasetBindingResponse.h +// QCloudDeleteDatasetBindingResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@interface QCloudDeleteDatasetBindingResponse : NSObject + +/// 请求ID +@property (nonatomic,strong) NSString * RequestId; + +@end + +@interface QCloudDeleteDatasetBinding : NSObject + +/// 数据集名称,同一个账户下唯一。;是否必传:是 +@property (nonatomic,strong) NSString * DatasetName; + +/// 资源标识字段,表示需要与数据集绑定的资源,当前仅支持COS存储桶,字段规则:cos://,其中BucketName表示COS存储桶名称,例如:cos://examplebucket-1250000000;是否必传:是 +@property (nonatomic,strong) NSString * URI; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudDeleteDatasetBindingResponse.m b/QCloudCOSXML/Classes/MateData/model/QCloudDeleteDatasetBindingResponse.m new file mode 100644 index 0000000..aeffa7b --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudDeleteDatasetBindingResponse.m @@ -0,0 +1,47 @@ +// +// QCloudDeleteDatasetBindingResponse.m +// QCloudDeleteDatasetBindingResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDeleteDatasetBindingResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudDeleteDatasetBindingResponse + +@end + +@implementation QCloudDeleteDatasetBinding + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudDeleteDatasetResponse.h b/QCloudCOSXML/Classes/MateData/model/QCloudDeleteDatasetResponse.h new file mode 100644 index 0000000..a057c2a --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudDeleteDatasetResponse.h @@ -0,0 +1,57 @@ +// +// QCloudDeleteDatasetResponse.h +// QCloudDeleteDatasetResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@interface QCloudDeleteDatasetResponse : NSObject + +/// 请求ID +@property (nonatomic,strong) NSString * RequestId; + +/// 数据集信息 +@property (nonatomic,strong) QCloudDataset * Dataset; + +@end + +@interface QCloudDeleteDataset : NSObject + +/// 数据集名称,同一个账户下唯一。;是否必传:是 +@property (nonatomic,strong) NSString * DatasetName; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudDeleteDatasetResponse.m b/QCloudCOSXML/Classes/MateData/model/QCloudDeleteDatasetResponse.m new file mode 100644 index 0000000..4c117cd --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudDeleteDatasetResponse.m @@ -0,0 +1,53 @@ +// +// QCloudDeleteDatasetResponse.m +// QCloudDeleteDatasetResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDeleteDatasetResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudDeleteDatasetResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Dataset" : [QCloudDataset class], + }; +} + +@end + +@implementation QCloudDeleteDataset + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudDeleteFileMetaIndexResponse.h b/QCloudCOSXML/Classes/MateData/model/QCloudDeleteFileMetaIndexResponse.h new file mode 100644 index 0000000..86f0d94 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudDeleteFileMetaIndexResponse.h @@ -0,0 +1,57 @@ +// +// QCloudDeleteFileMetaIndexResponse.h +// QCloudDeleteFileMetaIndexResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@interface QCloudDeleteFileMetaIndexResponse : NSObject + +/// 请求ID +@property (nonatomic,strong) NSString * RequestId; + +@end + +@interface QCloudDeleteFileMetaIndex : NSObject + +/// 数据集名称,同一个账户下唯一。;是否必传:是 +@property (nonatomic,strong) NSString * DatasetName; + +/// 资源标识字段,表示需要建立索引的文件地址。;是否必传:是 +@property (nonatomic,strong) NSString * URI; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudDeleteFileMetaIndexResponse.m b/QCloudCOSXML/Classes/MateData/model/QCloudDeleteFileMetaIndexResponse.m new file mode 100644 index 0000000..499ed40 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudDeleteFileMetaIndexResponse.m @@ -0,0 +1,47 @@ +// +// QCloudDeleteFileMetaIndexResponse.m +// QCloudDeleteFileMetaIndexResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDeleteFileMetaIndexResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudDeleteFileMetaIndexResponse + +@end + +@implementation QCloudDeleteFileMetaIndex + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetBindingResponse.h b/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetBindingResponse.h new file mode 100644 index 0000000..55852a5 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetBindingResponse.h @@ -0,0 +1,50 @@ +// +// QCloudDescribeDatasetBindingResponse.h +// QCloudDescribeDatasetBindingResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@interface QCloudDescribeDatasetBindingResponse : NSObject + +/// 请求ID +@property (nonatomic,strong) NSString * RequestId; + +/// 数据集和 COS Bucket 绑定关系信息的列表。 +@property (nonatomic,strong) QCloudBinding * Binding; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetBindingResponse.m b/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetBindingResponse.m new file mode 100644 index 0000000..f5a30fd --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetBindingResponse.m @@ -0,0 +1,49 @@ +// +// QCloudDescribeDatasetBindingResponse.m +// QCloudDescribeDatasetBindingResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDescribeDatasetBindingResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudDescribeDatasetBindingResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Binding" : [QCloudBinding class], + }; +} + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetBindingsResponse.h b/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetBindingsResponse.h new file mode 100644 index 0000000..8027e6f --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetBindingsResponse.h @@ -0,0 +1,53 @@ +// +// QCloudDescribeDatasetBindingsResponse.h +// QCloudDescribeDatasetBindingsResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@interface QCloudDescribeDatasetBindingsResponse : NSObject + +/// 请求ID +@property (nonatomic,strong) NSString * RequestId; + +/// 当绑定关系总数大于设置的MaxResults时,用于翻页的token。下一次列出绑定关系信息时以此值为NextToken,将未返回的结果返回。当绑定关系未全部返回时,此参数才有值。 +@property (nonatomic,strong) NSString * NextToken; + +/// 数据集和 COS Bucket 绑定关系信息的列表。 +@property (nonatomic,strong)NSArray * Bindings; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetBindingsResponse.m b/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetBindingsResponse.m new file mode 100644 index 0000000..1a4afcc --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetBindingsResponse.m @@ -0,0 +1,63 @@ +// +// QCloudDescribeDatasetBindingsResponse.m +// QCloudDescribeDatasetBindingsResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDescribeDatasetBindingsResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudDescribeDatasetBindingsResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Bindings" : [QCloudBinding class], + }; +} + +- (NSDictionary *)modelCustomWillTransformFromDictionary:(NSDictionary *)dic { + + if (!dic) {return dic;} + + if (![dic isKindOfClass:[NSDictionary class]]) {return nil;} + + if (dic[@"Bindings"] && [dic[@"Bindings"] isKindOfClass:[NSDictionary class]]){ + NSMutableDictionary * mdic = [NSMutableDictionary dictionaryWithDictionary:dic]; + [mdic setValue:@[dic[@"Bindings"]] forKey:@"Bindings"]; + dic = mdic.copy; + } + return dic; +} + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetResponse.h b/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetResponse.h new file mode 100644 index 0000000..ceb3f1c --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetResponse.h @@ -0,0 +1,50 @@ +// +// QCloudDescribeDatasetResponse.h +// QCloudDescribeDatasetResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@interface QCloudDescribeDatasetResponse : NSObject + +/// 请求ID +@property (nonatomic,strong) NSString * RequestId; + +/// 数据集信息 +@property (nonatomic,strong) QCloudDataset * Dataset; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetResponse.m b/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetResponse.m new file mode 100644 index 0000000..6d36cae --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetResponse.m @@ -0,0 +1,49 @@ +// +// QCloudDescribeDatasetResponse.m +// QCloudDescribeDatasetResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDescribeDatasetResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudDescribeDatasetResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Dataset" : [QCloudDataset class], + }; +} + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetsResponse.h b/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetsResponse.h new file mode 100644 index 0000000..905cb9d --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetsResponse.h @@ -0,0 +1,53 @@ +// +// QCloudDescribeDatasetsResponse.h +// QCloudDescribeDatasetsResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@interface QCloudDescribeDatasetsResponse : NSObject + +/// 请求ID +@property (nonatomic,strong) NSString * RequestId; + +/// 数据集信息 +@property (nonatomic,strong)NSArray * Datasets; + +/// 翻页标记。当任务列表总数大于设置的MaxResults时,用于翻页的Token。符合条件的任务列表未全部返回时,此参数才有值。下一次列出任务列表时将此值作为NextToken传入,将后续的任务列表返回。 +@property (nonatomic,strong) NSString * NextToken; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetsResponse.m b/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetsResponse.m new file mode 100644 index 0000000..6a50ac9 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudDescribeDatasetsResponse.m @@ -0,0 +1,63 @@ +// +// QCloudDescribeDatasetsResponse.m +// QCloudDescribeDatasetsResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDescribeDatasetsResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudDescribeDatasetsResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Datasets" : [QCloudDatasets class], + }; +} + +- (NSDictionary *)modelCustomWillTransformFromDictionary:(NSDictionary *)dic { + + if (!dic) {return dic;} + + if (![dic isKindOfClass:[NSDictionary class]]) {return nil;} + + if (dic[@"Datasets"] && [dic[@"Datasets"] isKindOfClass:[NSDictionary class]]){ + NSMutableDictionary * mdic = [NSMutableDictionary dictionaryWithDictionary:dic]; + [mdic setValue:@[dic[@"Datasets"]] forKey:@"Datasets"]; + dic = mdic.copy; + } + return dic; +} + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudDescribeFileMetaIndexResponse.h b/QCloudCOSXML/Classes/MateData/model/QCloudDescribeFileMetaIndexResponse.h new file mode 100644 index 0000000..26bfdec --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudDescribeFileMetaIndexResponse.h @@ -0,0 +1,50 @@ +// +// QCloudDescribeFileMetaIndexResponse.h +// QCloudDescribeFileMetaIndexResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@interface QCloudDescribeFileMetaIndexResponse : NSObject + +/// 请求ID。 +@property (nonatomic,strong) NSString * RequestId; + +/// 文件元数据的结构体。实际返回的数据可能并不包含该结构体的所有属性,这和您索引该文件时选用的工作流模板配置以及文件本身的内容有关。 +@property (nonatomic,strong)NSArray * Files; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudDescribeFileMetaIndexResponse.m b/QCloudCOSXML/Classes/MateData/model/QCloudDescribeFileMetaIndexResponse.m new file mode 100644 index 0000000..ea6b5cf --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudDescribeFileMetaIndexResponse.m @@ -0,0 +1,63 @@ +// +// QCloudDescribeFileMetaIndexResponse.m +// QCloudDescribeFileMetaIndexResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDescribeFileMetaIndexResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudDescribeFileMetaIndexResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Files" : [QCloudFilesDetail class], + }; +} + +- (NSDictionary *)modelCustomWillTransformFromDictionary:(NSDictionary *)dic { + + if (!dic) {return dic;} + + if (![dic isKindOfClass:[NSDictionary class]]) {return nil;} + + if (dic[@"Files"] && [dic[@"Files"] isKindOfClass:[NSDictionary class]]){ + NSMutableDictionary * mdic = [NSMutableDictionary dictionaryWithDictionary:dic]; + [mdic setValue:@[dic[@"Files"]] forKey:@"Files"]; + dic = mdic.copy; + } + return dic; +} + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudSearchImageResponse.h b/QCloudCOSXML/Classes/MateData/model/QCloudSearchImageResponse.h new file mode 100644 index 0000000..88dda76 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudSearchImageResponse.h @@ -0,0 +1,72 @@ +// +// QCloudSearchImageResponse.h +// QCloudSearchImageResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@interface QCloudSearchImageResponse : NSObject + +/// 图像检索识别结果信息列表。 +@property (nonatomic,strong)NSArray * ImageResult; + +/// 请求ID。 +@property (nonatomic,strong) NSString * RequestId; + +@end + +@interface QCloudSearchImage : NSObject + +/// 数据集名称,同一个账户下唯一。;是否必传:是 +@property (nonatomic,strong) NSString * DatasetName; + +/// 指定检索方式为图片或文本,pic 为图片检索,text 为文本检索,默认为 pic。;是否必传:否 +@property (nonatomic,strong) NSString * Mode; + +/// 资源标识字段,表示需要建立索引的文件地址(Mode 为 pic 时必选)。;是否必传:否 +@property (nonatomic,strong) NSString * URI; + +/// 返回相关图片的数量,默认值为10,最大值为100。;是否必传:否 +@property (nonatomic,assign) NSInteger Limit; + +/// 检索语句,检索方式为 text 时必填,最多支持60个字符 (Mode 为 text 时必选)。;是否必传:否 +@property (nonatomic,strong) NSString * Text; + +/// 出参 Score(相关图片匹配得分) 中,只有超过 MatchThreshold 值的结果才会返回。默认值为0,推荐值为80。;是否必传:否 +@property (nonatomic,assign) NSInteger MatchThreshold; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudSearchImageResponse.m b/QCloudCOSXML/Classes/MateData/model/QCloudSearchImageResponse.m new file mode 100644 index 0000000..b7673f1 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudSearchImageResponse.m @@ -0,0 +1,67 @@ +// +// QCloudSearchImageResponse.m +// QCloudSearchImageResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudSearchImageResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudSearchImageResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"ImageResult" : [QCloudImageResult class], + }; +} + +- (NSDictionary *)modelCustomWillTransformFromDictionary:(NSDictionary *)dic { + + if (!dic) {return dic;} + + if (![dic isKindOfClass:[NSDictionary class]]) {return nil;} + + if (dic[@"ImageResult"] && [dic[@"ImageResult"] isKindOfClass:[NSDictionary class]]){ + NSMutableDictionary * mdic = [NSMutableDictionary dictionaryWithDictionary:dic]; + [mdic setValue:@[dic[@"ImageResult"]] forKey:@"ImageResult"]; + dic = mdic.copy; + } + return dic; +} + +@end + +@implementation QCloudSearchImage + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudUpdateDatasetResponse.h b/QCloudCOSXML/Classes/MateData/model/QCloudUpdateDatasetResponse.h new file mode 100644 index 0000000..d5ca240 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudUpdateDatasetResponse.h @@ -0,0 +1,63 @@ +// +// QCloudUpdateDatasetResponse.h +// QCloudUpdateDatasetResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@interface QCloudUpdateDatasetResponse : NSObject + +/// 请求ID +@property (nonatomic,strong) NSString * RequestId; + +/// 数据集信息 +@property (nonatomic,strong) QCloudDataset * Dataset; + +@end + +@interface QCloudUpdateDataset : NSObject + +/// 数据集名称,同一个账户下唯一。;是否必传:是 +@property (nonatomic,strong) NSString * DatasetName; + +/// 数据集描述信息。长度为1~256个英文或中文字符,默认值为空。;是否必传:否 +@property (nonatomic,strong) NSString * Description; + +/// 检与数据集关联的检索模板,在建立元数据索引时,后端将根据检索模板来决定采集文件的哪些元数据。 每个检索模板都包含若干个算子,不同的算子表示不同的处理能力,更多信息请参见 [检索模板与算子](https://cloud.tencent.com/document/product/460/106018)。 默认值为空,即不关联检索模板,不进行任何元数据的采集。;是否必传:否 +@property (nonatomic,strong) NSString * TemplateId; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudUpdateDatasetResponse.m b/QCloudCOSXML/Classes/MateData/model/QCloudUpdateDatasetResponse.m new file mode 100644 index 0000000..16518fa --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudUpdateDatasetResponse.m @@ -0,0 +1,53 @@ +// +// QCloudUpdateDatasetResponse.m +// QCloudUpdateDatasetResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudUpdateDatasetResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudUpdateDatasetResponse + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"Dataset" : [QCloudDataset class], + }; +} + +@end + +@implementation QCloudUpdateDataset + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudUpdateFileMetaIndexResponse.h b/QCloudCOSXML/Classes/MateData/model/QCloudUpdateFileMetaIndexResponse.h new file mode 100644 index 0000000..b339ee8 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudUpdateFileMetaIndexResponse.h @@ -0,0 +1,60 @@ +// +// QCloudUpdateFileMetaIndexResponse.h +// QCloudUpdateFileMetaIndexResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCommonModel.h" + +NS_ASSUME_NONNULL_BEGIN + +@interface QCloudUpdateFileMetaIndexResponse : NSObject + +/// 请求ID +@property (nonatomic,strong) NSString * RequestId; + +/// 创建元数据索引的任务ID +@property (nonatomic,strong) NSString * EventId; + +@end + +@interface QCloudUpdateFileMetaIndex : NSObject + +/// 数据集名称,同一个账户下唯一。;是否必传:是 +@property (nonatomic,strong) NSString * DatasetName; + +/// 用于建立索引的文件信息。;是否必传:是 +@property (nonatomic,strong) QCloudUpdateMetaFile * File; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/model/QCloudUpdateFileMetaIndexResponse.m b/QCloudCOSXML/Classes/MateData/model/QCloudUpdateFileMetaIndexResponse.m new file mode 100644 index 0000000..9791e57 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/model/QCloudUpdateFileMetaIndexResponse.m @@ -0,0 +1,53 @@ +// +// QCloudUpdateFileMetaIndexResponse.m +// QCloudUpdateFileMetaIndexResponse +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudUpdateFileMetaIndexResponse.h" + + +NS_ASSUME_NONNULL_BEGIN + +@implementation QCloudUpdateFileMetaIndexResponse + +@end + +@implementation QCloudUpdateFileMetaIndex + ++ (NSDictionary *)modelContainerPropertyGenericClass { + return @{ + @"File" : [QCloudUpdateMetaFile class], + }; +} + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudCreateDatasetBindingRequest.h b/QCloudCOSXML/Classes/MateData/request/QCloudCreateDatasetBindingRequest.h new file mode 100644 index 0000000..8350c14 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudCreateDatasetBindingRequest.h @@ -0,0 +1,81 @@ +// +// QCloudCreateDatasetBindingRequest.h +// QCloudCreateDatasetBindingRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCreateDatasetBindingResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 绑定存储桶与数据集. + + ### 功能描述 + + 本文档介绍创建数据集(Dataset)和对象存储(COS)Bucket 的绑定关系,绑定后将使用创建数据集时所指定算子对文件进行处理。 +绑定关系创建后,将对 COS 中新增的文件进行准实时的增量追踪扫描,使用创建数据集时所指定算子对文件进行处理,抽取文件元数据信息进行索引。通过此方式为文件建立索引后,您可以使用元数据查询API对元数据进行查询、管理和统计。 +. + + 具体请查看 https://cloud.tencent.com/document/product/460/106159. + +### 示例 + + @code + + QCloudCreateDatasetBindingRequest * request = [QCloudCreateDatasetBindingRequest new]; + request.regionName = @"COS_REGIONNAME"; + request.input = [QCloudCreateDatasetBinding new]; + // 数据集名称,同一个账户下唯一;是否必传:是 + request.input.DatasetName = @"test"; + // 资源标识字段,表示需要与数据集绑定的资源,当前仅支持COS存储桶,字段规则:cos://,其中BucketName表示COS存储桶名称,例如:cos://examplebucket-1250000000;是否必传:是 + request.input.URI = @"cos://examplebucket-1250000000"; + + [request setFinishBlock:^(QCloudCreateDatasetBindingResponse * outputObject, NSError *error) { + // result:QCloudCreateDatasetBindingResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/106159 + }]; + [[QCloudCOSXMLService defaultCOSXML] CreateDatasetBinding:request]; + + +*/ + +@interface QCloudCreateDatasetBindingRequest : QCloudBizHTTPRequest + +/// 请求输入参数 +@property (nonatomic,strong)QCloudCreateDatasetBinding * input; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudCreateDatasetBindingResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudCreateDatasetBindingRequest.m b/QCloudCOSXML/Classes/MateData/request/QCloudCreateDatasetBindingRequest.m new file mode 100644 index 0000000..9be9095 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudCreateDatasetBindingRequest.m @@ -0,0 +1,82 @@ +// +// QCloudCreateDatasetBindingRequest.m +// QCloudCreateDatasetBindingRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudCreateDatasetBindingRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudCreateDatasetBindingRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + QCloudURLFuseWithJSONParamters, + QCloudURLFuseContentMD5Base64StyleHeaders + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseJSONSerilizerBlock, + QCloudResponseObjectSerilizerBlock([QCloudCreateDatasetBindingResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"post"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [NSURL URLWithString:[NSString stringWithFormat:@"%@://%@.ci.%@.%@",self.runOnService.configuration.endpoint.useHTTPS?@"https":@"http",self.runOnService.configuration.appID, self.regionName?:self.runOnService.configuration.endpoint.regionName, self.runOnService.configuration.endpoint.serviceName]]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:@"application/json" forHTTPHeaderField:@"Accept"]; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"datasetbinding"]; + self.requestData.URIComponents = __pathComponents; + + if (self.input) { + self.requestData.directBody = [self.input qcloud_modelToJSONData]; + } + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudCreateDatasetBindingResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudCreateDatasetRequest.h b/QCloudCOSXML/Classes/MateData/request/QCloudCreateDatasetRequest.h new file mode 100644 index 0000000..db335a4 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudCreateDatasetRequest.h @@ -0,0 +1,81 @@ +// +// QCloudCreateDatasetRequest.h +// QCloudCreateDatasetRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCreateDatasetResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 创建数据集. + + ### 功能描述 + + 本接口用于创建一个数据集(Dataset),数据集是由文件元数据构成的集合,用于存储和管理元数据。. + + 具体请查看 https://cloud.tencent.com/document/product/460/106020. + +### 示例 + + @code + + QCloudCreateDatasetRequest * request = [QCloudCreateDatasetRequest new]; + request.regionName = @"COS_REGIONNAME"; + request.input = [QCloudCreateDataset new]; + // 数据集名称,同一个账户下唯一。命名规则如下: 长度为1~32字符。 只能包含小写英文字母,数字,短划线(-)。 必须以英文字母和数字开头。;是否必传:是 + request.input.DatasetName = @"test"; + // 数据集描述信息。长度为1~256个英文或中文字符,默认值为空。;是否必传:否 + request.input.Description = @"test"; + // 与数据集关联的检索模板,在建立元数据索引时,后端将根据检索模板来决定采集文件的哪些元数据。每个检索模板都包含若干个算子,不同的算子表示不同的处理能力,更多信息请参见 [检索模板与算子](https://cloud.tencent.com/document/product/460/106018)。 默认值为空,即不关联检索模板,不进行任何元数据的采集。;是否必传:否 + request.input.TemplateId = @"Official:COSBasicMeta"; + + [request setFinishBlock:^(QCloudCreateDatasetResponse * outputObject, NSError *error) { + // result:QCloudCreateDatasetResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/106020 + }]; + [[QCloudCOSXMLService defaultCOSXML] CreateDataset:request]; + + +*/ + +@interface QCloudCreateDatasetRequest : QCloudBizHTTPRequest + +/// 请求输入参数 +@property (nonatomic,strong)QCloudCreateDataset * input; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudCreateDatasetResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudCreateDatasetRequest.m b/QCloudCOSXML/Classes/MateData/request/QCloudCreateDatasetRequest.m new file mode 100644 index 0000000..204064f --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudCreateDatasetRequest.m @@ -0,0 +1,82 @@ +// +// QCloudCreateDatasetRequest.m +// QCloudCreateDatasetRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudCreateDatasetRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudCreateDatasetRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + QCloudURLFuseWithJSONParamters, + QCloudURLFuseContentMD5Base64StyleHeaders + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseJSONSerilizerBlock, + QCloudResponseObjectSerilizerBlock([QCloudCreateDatasetResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"post"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [NSURL URLWithString:[NSString stringWithFormat:@"%@://%@.ci.%@.%@",self.runOnService.configuration.endpoint.useHTTPS?@"https":@"http",self.runOnService.configuration.appID, self.regionName?:self.runOnService.configuration.endpoint.regionName, self.runOnService.configuration.endpoint.serviceName]]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:@"application/json" forHTTPHeaderField:@"Accept"]; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"dataset"]; + self.requestData.URIComponents = __pathComponents; + + if (self.input) { + self.requestData.directBody = [self.input qcloud_modelToJSONData]; + } + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudCreateDatasetResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudCreateFileMetaIndexRequest.h b/QCloudCOSXML/Classes/MateData/request/QCloudCreateFileMetaIndexRequest.h new file mode 100644 index 0000000..fd52832 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudCreateFileMetaIndexRequest.h @@ -0,0 +1,93 @@ +// +// QCloudCreateFileMetaIndexRequest.h +// QCloudCreateFileMetaIndexRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudCreateFileMetaIndexResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 创建元数据索引. + + ### 功能描述 + + 提取一个 COS 文件的元数据,在数据集中建立索引。会根据数据集中的算子提取不同的元数据建立索引,也支持建立自定义的元数据索引。. + + 具体请查看 https://cloud.tencent.com/document/product/460/106022. + +### 示例 + + @code + + QCloudCreateFileMetaIndexRequest * request = [QCloudCreateFileMetaIndexRequest new]; + request.regionName = @"COS_REGIONNAME"; + request.input = [QCloudCreateFileMetaIndex new]; + // 数据集名称,同一个账户下唯一。;是否必传:是 + request.input.DatasetName = @"test001"; + // 用于建立索引的文件信息。;是否必传:是 + request.input.File = [QCloudFile new]; + // 自定义ID。该文件索引到数据集后,作为该行元数据的属性存储,用于和您的业务系统进行关联、对应。您可以根据业务需求传入该值,例如将某个URI关联到您系统内的某个ID。推荐传入全局唯一的值。在查询时,该字段支持前缀查询和排序,详情请见[字段和操作符的支持列表](https://cloud.tencent.com/document/product/460/106154)。 ;是否必传:否 + request.input.File.CustomId = @"001"; + // 自定义标签。您可以根据业务需要自定义添加标签键值对信息,用于在查询时可以据此为筛选项进行检索,详情请见[字段和操作符的支持列表](https://cloud.tencent.com/document/product/460/106154)。 ;是否必传:否 + request.input.File.CustomLabels = [object Object]; + // 可选项,文件媒体类型,枚举值: image:图片。 other:其他。 document:文档。 archive:压缩包。 video:视频。 audio:音频。 ;是否必传:否 + request.input.File.MediaType = @"image"; + // 可选项,文件内容类型(MIME Type),如image/jpeg。 ;是否必传:否 + request.input.File.ContentType = @"image/jpeg"; + // 资源标识字段,表示需要建立索引的文件地址,当前仅支持COS上的文件,字段规则:cos:///,其中BucketName表示COS存储桶名称,ObjectKey表示文件完整路径,例如:cos://examplebucket-1250000000/test1/img.jpg。 注意: 1、仅支持本账号内的COS文件 2、不支持HTTP开头的地址;是否必传:是 + request.input.File.URI = @"cos://examplebucket-1250000000/test.jpg"; + // 输入图片中检索的人脸数量,默认值为20,最大值为20。(仅当数据集模板 ID 为 Official:FaceSearch 有效)。;是否必传:否 + request.input.File.MaxFaceNum = 20; + // 自定义人物属性(仅当数据集模板 ID 为 Official:FaceSearch 有效)。;是否必传:否 + request.input.File.Persons = [QCloudPersons new]; + + [request setFinishBlock:^(QCloudCreateFileMetaIndexResponse * outputObject, NSError *error) { + // result:QCloudCreateFileMetaIndexResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/106022 + }]; + [[QCloudCOSXMLService defaultCOSXML] CreateFileMetaIndex:request]; + + +*/ + +@interface QCloudCreateFileMetaIndexRequest : QCloudBizHTTPRequest + +/// 请求输入参数 +@property (nonatomic,strong)QCloudCreateFileMetaIndex * input; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudCreateFileMetaIndexResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudCreateFileMetaIndexRequest.m b/QCloudCOSXML/Classes/MateData/request/QCloudCreateFileMetaIndexRequest.m new file mode 100644 index 0000000..f7f8c54 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudCreateFileMetaIndexRequest.m @@ -0,0 +1,82 @@ +// +// QCloudCreateFileMetaIndexRequest.m +// QCloudCreateFileMetaIndexRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudCreateFileMetaIndexRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudCreateFileMetaIndexRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + QCloudURLFuseWithJSONParamters, + QCloudURLFuseContentMD5Base64StyleHeaders + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseJSONSerilizerBlock, + QCloudResponseObjectSerilizerBlock([QCloudCreateFileMetaIndexResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"post"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [NSURL URLWithString:[NSString stringWithFormat:@"%@://%@.ci.%@.%@",self.runOnService.configuration.endpoint.useHTTPS?@"https":@"http",self.runOnService.configuration.appID, self.regionName?:self.runOnService.configuration.endpoint.regionName, self.runOnService.configuration.endpoint.serviceName]]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:@"application/json" forHTTPHeaderField:@"Accept"]; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"filemeta"]; + self.requestData.URIComponents = __pathComponents; + + if (self.input) { + self.requestData.directBody = [self.input qcloud_modelToJSONData]; + } + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudCreateFileMetaIndexResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudDatasetFaceSearchRequest.h b/QCloudCOSXML/Classes/MateData/request/QCloudDatasetFaceSearchRequest.h new file mode 100644 index 0000000..491bb05 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudDatasetFaceSearchRequest.h @@ -0,0 +1,85 @@ +// +// QCloudDatasetFaceSearchRequest.h +// QCloudDatasetFaceSearchRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudDatasetFaceSearchResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 人脸搜索. + + ### 功能描述 + + 从数据集中搜索与指定图片最相似的前N张图片并返回人脸坐标可对数据集内文件进行一个或多个人员的人脸识别。. + + 具体请查看 https://cloud.tencent.com/document/product/460/106166. + +### 示例 + + @code + + QCloudDatasetFaceSearchRequest * request = [QCloudDatasetFaceSearchRequest new]; + request.regionName = @"COS_REGIONNAME"; + request.input = [QCloudDatasetFaceSearch new]; + // 数据集名称,同一个账户下唯一。;是否必传:是 + request.input.DatasetName = @"test"; + // 资源标识字段,表示需要建立索引的文件地址。;是否必传:是 + request.input.URI = @"cos://examplebucket-1250000000/test.jpg"; + // 输入图片中检索的人脸数量,默认值为1(传0或不传采用默认值),最大值为10。;是否必传:否 + request.input.MaxFaceNum = 1; + // 检索的每张人脸返回相关人脸数量,默认值为10,最大值为100。;是否必传:否 + request.input.Limit = 10; + // 限制返回人脸的最低相关度分数,只有超过 MatchThreshold 值的人脸才会返回。默认值为0,推荐值为80。 例如:设置 MatchThreshold 的值为80,则检索结果中仅会返回相关度分数大于等于80分的人脸。;是否必传:否 + request.input.MatchThreshold = 10; + + [request setFinishBlock:^(QCloudDatasetFaceSearchResponse * outputObject, NSError *error) { + // result:QCloudDatasetFaceSearchResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/106166 + }]; + [[QCloudCOSXMLService defaultCOSXML] DatasetFaceSearch:request]; + + +*/ + +@interface QCloudDatasetFaceSearchRequest : QCloudBizHTTPRequest + +/// 请求输入参数 +@property (nonatomic,strong)QCloudDatasetFaceSearch * input; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudDatasetFaceSearchResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudDatasetFaceSearchRequest.m b/QCloudCOSXML/Classes/MateData/request/QCloudDatasetFaceSearchRequest.m new file mode 100644 index 0000000..fbf18a0 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudDatasetFaceSearchRequest.m @@ -0,0 +1,83 @@ +// +// QCloudDatasetFaceSearchRequest.m +// QCloudDatasetFaceSearchRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDatasetFaceSearchRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudDatasetFaceSearchRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + QCloudURLFuseWithJSONParamters, + QCloudURLFuseContentMD5Base64StyleHeaders + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseJSONSerilizerBlock, + QCloudResponseObjectSerilizerBlock([QCloudDatasetFaceSearchResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"post"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [NSURL URLWithString:[NSString stringWithFormat:@"%@://%@.ci.%@.%@",self.runOnService.configuration.endpoint.useHTTPS?@"https":@"http",self.runOnService.configuration.appID, self.regionName?:self.runOnService.configuration.endpoint.regionName, self.runOnService.configuration.endpoint.serviceName]]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:@"application/json" forHTTPHeaderField:@"Accept"]; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"datasetquery"]; + [__pathComponents addObject:@"facesearch"]; + self.requestData.URIComponents = __pathComponents; + + if (self.input) { + self.requestData.directBody = [self.input qcloud_modelToJSONData]; + } + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudDatasetFaceSearchResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudDatasetSimpleQueryRequest.h b/QCloudCOSXML/Classes/MateData/request/QCloudDatasetSimpleQueryRequest.h new file mode 100644 index 0000000..a868ce3 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudDatasetSimpleQueryRequest.h @@ -0,0 +1,89 @@ +// +// QCloudDatasetSimpleQueryRequest.h +// QCloudDatasetSimpleQueryRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudDatasetSimpleQueryResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 简单查询. + + ### 功能描述 + + 可以根据已提取的文件元数据(包含文件名、标签、路径、自定义标签、文本等字段)查询和统计数据集内文件,支持逻辑关系表达方式。. + + 具体请查看 https://cloud.tencent.com/document/product/460/106375. + +### 示例 + + @code + + QCloudDatasetSimpleQueryRequest * request = [QCloudDatasetSimpleQueryRequest new]; + request.regionName = @"COS_REGIONNAME"; + request.input = [QCloudDatasetSimpleQuery new]; + // 数据集名称,同一个账户下唯一。;是否必传:是 + request.input.DatasetName = @"test"; + // 简单查询参数条件,可自嵌套。;是否必传:否 + request.input.Query = [QCloudQuery new]; + // 操作运算符。枚举值: not:逻辑非。 or:逻辑或。 and:逻辑与。 lt:小于。 lte:小于等于。 gt:大于。 gte:大于等于。 eq:等于。 exist:存在性查询。 prefix:前缀查询。 match-phrase:字符串匹配查询。 nested:字段为数组时,其中同一对象内逻辑条件查询。;是否必传:是 + request.input.Query.Operation = @"and"; + // 子查询的结构体。 只有当Operations为逻辑运算符(and、or、not或nested)时,才能设置子查询条件。 在逻辑运算符为and/or/not时,其SubQueries内描述的所有条件需符合父级设置的and/or/not逻辑关系。 在逻辑运算符为nested时,其父级的Field必须为一个数组类的字段(如:Labels)。 子查询条件SubQueries组的Operation必须为and/or/not中的一个或多个,其Field必须为父级Field的子属性。;是否必传:否 + request.input.Query.SubQueries = [QCloudSubQueries new]; + // 返回文件元数据的最大个数,取值范围为0200。 使用聚合参数时,该值表示返回分组的最大个数,取值范围为02000。 不设置此参数或者设置为0时,则取默认值100。;是否必传:否 + request.input.MaxResults = 100; + // 排序字段列表。请参考[字段和操作符的支持列表](https://cloud.tencent.com/document/product/460/106154)。 多个排序字段可使用半角逗号(,)分隔,例如:Size,Filename。 最多可设置5个排序字段。 排序字段顺序即为排序优先级顺序。;是否必传:否 + request.input.Sort = @"CustomId"; + // 排序字段的排序方式。取值如下: asc:升序; desc(默认):降序。 多个排序方式可使用半角逗号(,)分隔,例如:asc,desc。 排序方式不可多于排序字段,即参数Order的元素数量需小于等于参数Sort的元素数量。例如Sort取值为Size,Filename时,Order可取值为asc,desc或asc。 排序方式少于排序字段时,未排序的字段默认取值asc。例如Sort取值为Size,Filename,Order取值为asc时,Filename默认排序方式为asc,即升序排列;是否必传:否 + request.input.Order = @"desc"; + + [request setFinishBlock:^(QCloudDatasetSimpleQueryResponse * outputObject, NSError *error) { + // result:QCloudDatasetSimpleQueryResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/106375 + }]; + [[QCloudCOSXMLService defaultCOSXML] DatasetSimpleQuery:request]; + + +*/ + +@interface QCloudDatasetSimpleQueryRequest : QCloudBizHTTPRequest + +/// 请求输入参数 +@property (nonatomic,strong)QCloudDatasetSimpleQuery * input; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudDatasetSimpleQueryResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudDatasetSimpleQueryRequest.m b/QCloudCOSXML/Classes/MateData/request/QCloudDatasetSimpleQueryRequest.m new file mode 100644 index 0000000..57e66ed --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudDatasetSimpleQueryRequest.m @@ -0,0 +1,83 @@ +// +// QCloudDatasetSimpleQueryRequest.m +// QCloudDatasetSimpleQueryRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDatasetSimpleQueryRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudDatasetSimpleQueryRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + QCloudURLFuseWithJSONParamters, + QCloudURLFuseContentMD5Base64StyleHeaders + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseJSONSerilizerBlock, + QCloudResponseObjectSerilizerBlock([QCloudDatasetSimpleQueryResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"post"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [NSURL URLWithString:[NSString stringWithFormat:@"%@://%@.ci.%@.%@",self.runOnService.configuration.endpoint.useHTTPS?@"https":@"http",self.runOnService.configuration.appID, self.regionName?:self.runOnService.configuration.endpoint.regionName, self.runOnService.configuration.endpoint.serviceName]]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:@"application/json" forHTTPHeaderField:@"Accept"]; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"datasetquery"]; + [__pathComponents addObject:@"simple"]; + self.requestData.URIComponents = __pathComponents; + + if (self.input) { + self.requestData.directBody = [self.input qcloud_modelToJSONData]; + } + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudDatasetSimpleQueryResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudDeleteDatasetBindingRequest.h b/QCloudCOSXML/Classes/MateData/request/QCloudDeleteDatasetBindingRequest.h new file mode 100644 index 0000000..5ac9c69 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudDeleteDatasetBindingRequest.h @@ -0,0 +1,79 @@ +// +// QCloudDeleteDatasetBindingRequest.h +// QCloudDeleteDatasetBindingRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudDeleteDatasetBindingResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 解绑存储桶与数据集. + + ### 功能描述 + + 解绑数据集和对象存储(COS)Bucket ,解绑会导致 COS Bucket新增的变更不会同步到数据集,请谨慎操作。. + + 具体请查看 https://cloud.tencent.com/document/product/460/106160. + +### 示例 + + @code + + QCloudDeleteDatasetBindingRequest * request = [QCloudDeleteDatasetBindingRequest new]; + request.regionName = @"COS_REGIONNAME"; + request.input = [QCloudDeleteDatasetBinding new]; + // 数据集名称,同一个账户下唯一。;是否必传:是 + request.input.DatasetName = @"test"; + // 资源标识字段,表示需要与数据集绑定的资源,当前仅支持COS存储桶,字段规则:cos://,其中BucketName表示COS存储桶名称,例如:cos://examplebucket-1250000000;是否必传:是 + request.input.URI = @"cos://examplebucket-1250000000"; + + [request setFinishBlock:^(QCloudDeleteDatasetBindingResponse * outputObject, NSError *error) { + // result:QCloudDeleteDatasetBindingResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/106160 + }]; + [[QCloudCOSXMLService defaultCOSXML] DeleteDatasetBinding:request]; + + +*/ + +@interface QCloudDeleteDatasetBindingRequest : QCloudBizHTTPRequest + +/// 请求输入参数 +@property (nonatomic,strong)QCloudDeleteDatasetBinding * input; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudDeleteDatasetBindingResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudDeleteDatasetBindingRequest.m b/QCloudCOSXML/Classes/MateData/request/QCloudDeleteDatasetBindingRequest.m new file mode 100644 index 0000000..3e243e2 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudDeleteDatasetBindingRequest.m @@ -0,0 +1,82 @@ +// +// QCloudDeleteDatasetBindingRequest.m +// QCloudDeleteDatasetBindingRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDeleteDatasetBindingRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudDeleteDatasetBindingRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + QCloudURLFuseWithJSONParamters, + QCloudURLFuseContentMD5Base64StyleHeaders + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseJSONSerilizerBlock, + QCloudResponseObjectSerilizerBlock([QCloudDeleteDatasetBindingResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"delete"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [NSURL URLWithString:[NSString stringWithFormat:@"%@://%@.ci.%@.%@",self.runOnService.configuration.endpoint.useHTTPS?@"https":@"http",self.runOnService.configuration.appID, self.regionName?:self.runOnService.configuration.endpoint.regionName, self.runOnService.configuration.endpoint.serviceName]]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:@"application/json" forHTTPHeaderField:@"Accept"]; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"datasetbinding"]; + self.requestData.URIComponents = __pathComponents; + + if (self.input) { + self.requestData.directBody = [self.input qcloud_modelToJSONData]; + } + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudDeleteDatasetBindingResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudDeleteDatasetRequest.h b/QCloudCOSXML/Classes/MateData/request/QCloudDeleteDatasetRequest.h new file mode 100644 index 0000000..1b3b7c7 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudDeleteDatasetRequest.h @@ -0,0 +1,77 @@ +// +// QCloudDeleteDatasetRequest.h +// QCloudDeleteDatasetRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudDeleteDatasetResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 删除数据集. + + ### 功能描述 + + 删除一个数据集(Dataset)。. + + 具体请查看 https://cloud.tencent.com/document/product/460/106157. + +### 示例 + + @code + + QCloudDeleteDatasetRequest * request = [QCloudDeleteDatasetRequest new]; + request.regionName = @"COS_REGIONNAME"; + request.input = [QCloudDeleteDataset new]; + // 数据集名称,同一个账户下唯一。;是否必传:是 + request.input.DatasetName = @"test"; + + [request setFinishBlock:^(QCloudDeleteDatasetResponse * outputObject, NSError *error) { + // result:QCloudDeleteDatasetResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/106157 + }]; + [[QCloudCOSXMLService defaultCOSXML] DeleteDataset:request]; + + +*/ + +@interface QCloudDeleteDatasetRequest : QCloudBizHTTPRequest + +/// 请求输入参数 +@property (nonatomic,strong)QCloudDeleteDataset * input; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudDeleteDatasetResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudDeleteDatasetRequest.m b/QCloudCOSXML/Classes/MateData/request/QCloudDeleteDatasetRequest.m new file mode 100644 index 0000000..a8b8594 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudDeleteDatasetRequest.m @@ -0,0 +1,82 @@ +// +// QCloudDeleteDatasetRequest.m +// QCloudDeleteDatasetRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDeleteDatasetRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudDeleteDatasetRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + QCloudURLFuseWithJSONParamters, + QCloudURLFuseContentMD5Base64StyleHeaders + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseJSONSerilizerBlock, + QCloudResponseObjectSerilizerBlock([QCloudDeleteDatasetResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"delete"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [NSURL URLWithString:[NSString stringWithFormat:@"%@://%@.ci.%@.%@",self.runOnService.configuration.endpoint.useHTTPS?@"https":@"http",self.runOnService.configuration.appID, self.regionName?:self.runOnService.configuration.endpoint.regionName, self.runOnService.configuration.endpoint.serviceName]]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:@"application/json" forHTTPHeaderField:@"Accept"]; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"dataset"]; + self.requestData.URIComponents = __pathComponents; + + if (self.input) { + self.requestData.directBody = [self.input qcloud_modelToJSONData]; + } + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudDeleteDatasetResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudDeleteFileMetaIndexRequest.h b/QCloudCOSXML/Classes/MateData/request/QCloudDeleteFileMetaIndexRequest.h new file mode 100644 index 0000000..360a209 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudDeleteFileMetaIndexRequest.h @@ -0,0 +1,81 @@ +// +// QCloudDeleteFileMetaIndexRequest.h +// QCloudDeleteFileMetaIndexRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudDeleteFileMetaIndexResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 删除元数据索引. + + ### 功能描述 + + 从数据集内删除一个文件的元信息。无论该文件的元信息是否在数据集内存在,均会返回删除成功。 + +. + + 具体请查看 https://cloud.tencent.com/document/product/460/106163. + +### 示例 + + @code + + QCloudDeleteFileMetaIndexRequest * request = [QCloudDeleteFileMetaIndexRequest new]; + request.regionName = @"COS_REGIONNAME"; + request.input = [QCloudDeleteFileMetaIndex new]; + // 数据集名称,同一个账户下唯一。;是否必传:是 + request.input.DatasetName = @"test"; + // 资源标识字段,表示需要建立索引的文件地址。;是否必传:是 + request.input.URI = @"cos://examplebucket-1250000000/test.jpg"; + + [request setFinishBlock:^(QCloudDeleteFileMetaIndexResponse * outputObject, NSError *error) { + // result:QCloudDeleteFileMetaIndexResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/106163 + }]; + [[QCloudCOSXMLService defaultCOSXML] DeleteFileMetaIndex:request]; + + +*/ + +@interface QCloudDeleteFileMetaIndexRequest : QCloudBizHTTPRequest + +/// 请求输入参数 +@property (nonatomic,strong)QCloudDeleteFileMetaIndex * input; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudDeleteFileMetaIndexResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudDeleteFileMetaIndexRequest.m b/QCloudCOSXML/Classes/MateData/request/QCloudDeleteFileMetaIndexRequest.m new file mode 100644 index 0000000..433a035 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudDeleteFileMetaIndexRequest.m @@ -0,0 +1,82 @@ +// +// QCloudDeleteFileMetaIndexRequest.m +// QCloudDeleteFileMetaIndexRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDeleteFileMetaIndexRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudDeleteFileMetaIndexRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + QCloudURLFuseWithJSONParamters, + QCloudURLFuseContentMD5Base64StyleHeaders + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseJSONSerilizerBlock, + QCloudResponseObjectSerilizerBlock([QCloudDeleteFileMetaIndexResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"delete"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [NSURL URLWithString:[NSString stringWithFormat:@"%@://%@.ci.%@.%@",self.runOnService.configuration.endpoint.useHTTPS?@"https":@"http",self.runOnService.configuration.appID, self.regionName?:self.runOnService.configuration.endpoint.regionName, self.runOnService.configuration.endpoint.serviceName]]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + [self.requestData setValue:@"application/json" forHTTPHeaderField:@"Accept"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"filemeta"]; + self.requestData.URIComponents = __pathComponents; + + if (self.input) { + self.requestData.directBody = [self.input qcloud_modelToJSONData]; + } + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudDeleteFileMetaIndexResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetBindingRequest.h b/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetBindingRequest.h new file mode 100644 index 0000000..864b379 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetBindingRequest.h @@ -0,0 +1,81 @@ +// +// QCloudDescribeDatasetBindingRequest.h +// QCloudDescribeDatasetBindingRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudDescribeDatasetBindingResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 查询数据集与存储桶的绑定关系. + + ### 功能描述 + + 查询数据集和对象存储(COS)Bucket 绑定关系列表。. + + 具体请查看 https://cloud.tencent.com/document/product/460/106485. + +### 示例 + + @code + + QCloudDescribeDatasetBindingRequest * request = [QCloudDescribeDatasetBindingRequest new]; + request.regionName = @"COS_REGIONNAME"; + // 数据集名称,同一个账户下唯一。;是否必传:true; + request.datasetname = @"数据集名称"; + // 资源标识字段,表示需要与数据集绑定的资源,当前仅支持COS存储桶,字段规则:cos://,其中BucketName表示COS存储桶名称,例如(需要进行urlencode):cos%3A%2F%2Fexample-125000;是否必传:true; + request.uri = @"uri"; + + [request setFinishBlock:^(QCloudDescribeDatasetBindingResponse * outputObject, NSError *error) { + // result:QCloudDescribeDatasetBindingResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/106485 + }]; + [[QCloudCOSXMLService defaultCOSXML] DescribeDatasetBinding:request]; + + +*/ + +@interface QCloudDescribeDatasetBindingRequest : QCloudBizHTTPRequest + +/// 数据集名称,同一个账户下唯一。;是否必传:是 +@property (nonatomic,strong) NSString * datasetname; + +/// 资源标识字段,表示需要与数据集绑定的资源,当前仅支持COS存储桶,字段规则:cos://,其中BucketName表示COS存储桶名称,例如(需要进行urlencode):cos%3A%2F%2Fexample-125000;是否必传:是 +@property (nonatomic,strong) NSString * uri; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudDescribeDatasetBindingResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetBindingRequest.m b/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetBindingRequest.m new file mode 100644 index 0000000..3c556c1 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetBindingRequest.m @@ -0,0 +1,83 @@ +// +// QCloudDescribeDatasetBindingRequest.m +// QCloudDescribeDatasetBindingRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDescribeDatasetBindingRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudDescribeDatasetBindingRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseJSONSerilizerBlock, + QCloudResponseObjectSerilizerBlock([QCloudDescribeDatasetBindingResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"get"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [NSURL URLWithString:[NSString stringWithFormat:@"%@://%@.ci.%@.%@",self.runOnService.configuration.endpoint.useHTTPS?@"https":@"http",self.runOnService.configuration.appID, self.regionName?:self.runOnService.configuration.endpoint.regionName, self.runOnService.configuration.endpoint.serviceName]]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:@"application/json" forHTTPHeaderField:@"Accept"]; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"datasetbinding"]; + self.requestData.URIComponents = __pathComponents; + + if (self.datasetname) { + [self.requestData setQueryStringParamter:self.datasetname withKey:@"datasetname"]; + } + if (self.uri) { + [self.requestData setQueryStringParamter:self.uri withKey:@"uri"]; + } + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudDescribeDatasetBindingResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetBindingsRequest.h b/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetBindingsRequest.h new file mode 100644 index 0000000..c83aaa3 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetBindingsRequest.h @@ -0,0 +1,86 @@ +// +// QCloudDescribeDatasetBindingsRequest.h +// QCloudDescribeDatasetBindingsRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudDescribeDatasetBindingsResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 查询绑定关系列表. + + ### 功能描述 + + 查询数据集和对象存储(COS)Bucket 绑定关系列表。. + + 具体请查看 https://cloud.tencent.com/document/product/460/106161. + +### 示例 + + @code + + QCloudDescribeDatasetBindingsRequest * request = [QCloudDescribeDatasetBindingsRequest new]; + request.regionName = @"COS_REGIONNAME"; + // 数据集名称,同一个账户下唯一。;是否必传:true; + request.datasetname = @"数据集名称"; + // 返回绑定关系的最大个数,取值范围为0~200。不设置此参数或者设置为0时,则默认值为100。;是否必传:false; + request.maxresults = 100; + // 当绑定关系总数大于设置的MaxResults时,用于翻页的token。从NextToken开始按字典序返回绑定关系信息列表。第一次调用此接口时,设置为空。;是否必传:false; + request.nexttoken = @"下一页"; + + [request setFinishBlock:^(QCloudDescribeDatasetBindingsResponse * outputObject, NSError *error) { + // result:QCloudDescribeDatasetBindingsResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/106161 + }]; + [[QCloudCOSXMLService defaultCOSXML] DescribeDatasetBindings:request]; + + +*/ + +@interface QCloudDescribeDatasetBindingsRequest : QCloudBizHTTPRequest + +/// 数据集名称,同一个账户下唯一。;是否必传:是 +@property (nonatomic,strong) NSString * datasetname; + +/// 返回绑定关系的最大个数,取值范围为0~200。不设置此参数或者设置为0时,则默认值为100。;是否必传:否 +@property (nonatomic,assign)NSInteger maxresults; + +/// 当绑定关系总数大于设置的MaxResults时,用于翻页的token。从NextToken开始按字典序返回绑定关系信息列表。第一次调用此接口时,设置为空。;是否必传:否 +@property (nonatomic,strong) NSString * nexttoken; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudDescribeDatasetBindingsResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetBindingsRequest.m b/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetBindingsRequest.m new file mode 100644 index 0000000..984e01f --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetBindingsRequest.m @@ -0,0 +1,84 @@ +// +// QCloudDescribeDatasetBindingsRequest.m +// QCloudDescribeDatasetBindingsRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDescribeDatasetBindingsRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudDescribeDatasetBindingsRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseJSONSerilizerBlock, + QCloudResponseObjectSerilizerBlock([QCloudDescribeDatasetBindingsResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"get"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [NSURL URLWithString:[NSString stringWithFormat:@"%@://%@.ci.%@.%@",self.runOnService.configuration.endpoint.useHTTPS?@"https":@"http",self.runOnService.configuration.appID, self.regionName?:self.runOnService.configuration.endpoint.regionName, self.runOnService.configuration.endpoint.serviceName]]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:@"application/json" forHTTPHeaderField:@"Accept"]; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"datasetbindings"]; + self.requestData.URIComponents = __pathComponents; + + if (self.datasetname) { + [self.requestData setQueryStringParamter:self.datasetname withKey:@"datasetname"]; + } + [self.requestData setQueryStringParamter:@(self.maxresults).stringValue withKey:@"maxresults"]; + if (self.nexttoken) { + [self.requestData setQueryStringParamter:self.nexttoken withKey:@"nexttoken"]; + } + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudDescribeDatasetBindingsResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetRequest.h b/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetRequest.h new file mode 100644 index 0000000..0a69883 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetRequest.h @@ -0,0 +1,79 @@ +// +// QCloudDescribeDatasetRequest.h +// QCloudDescribeDatasetRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudDescribeDatasetResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 查询数据集. + + ### 功能描述 + + 查询一个数据集(Dataset)信息。. + + 具体请查看 https://cloud.tencent.com/document/product/460/106155. + +### 示例 + + @code + + QCloudDescribeDatasetRequest * request = [QCloudDescribeDatasetRequest new]; + request.regionName = @"COS_REGIONNAME"; + // 数据集名称,同一个账户下唯一。;是否必传:true; + request.datasetname = @"数据集名称"; + + [request setFinishBlock:^(QCloudDescribeDatasetResponse * outputObject, NSError *error) { + // result:QCloudDescribeDatasetResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/106155 + }]; + [[QCloudCOSXMLService defaultCOSXML] DescribeDataset:request]; + + +*/ + +@interface QCloudDescribeDatasetRequest : QCloudBizHTTPRequest + +/// 数据集名称,同一个账户下唯一。;是否必传:是 +@property (nonatomic,strong) NSString * datasetname; + +/// 是否需要实时统计数据集中文件相关信息。有效值: false:不统计,返回的文件的总大小、数量信息可能不正确也可能都为0。 true:需要统计,返回数据集中当前的文件的总大小、数量信息。 默认值为false。;是否必传:否 +@property (nonatomic,assign)BOOL statistics; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudDescribeDatasetResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetRequest.m b/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetRequest.m new file mode 100644 index 0000000..632e417 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetRequest.m @@ -0,0 +1,81 @@ +// +// QCloudDescribeDatasetRequest.m +// QCloudDescribeDatasetRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDescribeDatasetRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudDescribeDatasetRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseJSONSerilizerBlock, + QCloudResponseObjectSerilizerBlock([QCloudDescribeDatasetResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"get"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [NSURL URLWithString:[NSString stringWithFormat:@"%@://%@.ci.%@.%@",self.runOnService.configuration.endpoint.useHTTPS?@"https":@"http",self.runOnService.configuration.appID, self.regionName?:self.runOnService.configuration.endpoint.regionName, self.runOnService.configuration.endpoint.serviceName]]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:@"application/json" forHTTPHeaderField:@"Accept"]; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"dataset"]; + self.requestData.URIComponents = __pathComponents; + + if (self.datasetname) { + [self.requestData setQueryStringParamter:self.datasetname withKey:@"datasetname"]; + } + [self.requestData setQueryStringParamter:self.statistics?@"true":@"false" withKey:@"statistics"]; + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudDescribeDatasetResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetsRequest.h b/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetsRequest.h new file mode 100644 index 0000000..90e701d --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetsRequest.h @@ -0,0 +1,86 @@ +// +// QCloudDescribeDatasetsRequest.h +// QCloudDescribeDatasetsRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudDescribeDatasetsResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 列出数据集. + + ### 功能描述 + + 获取数据集(Dataset)列表。. + + 具体请查看 https://cloud.tencent.com/document/product/460/106158. + +### 示例 + + @code + + QCloudDescribeDatasetsRequest * request = [QCloudDescribeDatasetsRequest new]; + request.regionName = @"COS_REGIONNAME"; + // 本次返回数据集的最大个数,取值范围为0~200。不设置此参数或者设置为0时,则默认值为100。;是否必传:false; + request.maxresults = 100; + // 翻页标记。当文件总数大于设置的MaxResults时,用于翻页的Token。从NextToken开始按字典序返回文件信息列表。填写上次查询返回的值,首次使用时填写为空。;是否必传:false; + request.nexttoken = @"下一页"; + // 数据集名称前缀。;是否必传:false; + request.prefix = @"数据集前缀"; + + [request setFinishBlock:^(QCloudDescribeDatasetsResponse * outputObject, NSError *error) { + // result:QCloudDescribeDatasetsResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/106158 + }]; + [[QCloudCOSXMLService defaultCOSXML] DescribeDatasets:request]; + + +*/ + +@interface QCloudDescribeDatasetsRequest : QCloudBizHTTPRequest + +/// 本次返回数据集的最大个数,取值范围为0~200。不设置此参数或者设置为0时,则默认值为100。;是否必传:否 +@property (nonatomic,assign)NSInteger maxresults; + +/// 翻页标记。当文件总数大于设置的MaxResults时,用于翻页的Token。从NextToken开始按字典序返回文件信息列表。填写上次查询返回的值,首次使用时填写为空。;是否必传:否 +@property (nonatomic,strong) NSString * nexttoken; + +/// 数据集名称前缀。;是否必传:否 +@property (nonatomic,strong) NSString * prefix; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudDescribeDatasetsResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetsRequest.m b/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetsRequest.m new file mode 100644 index 0000000..3a430d7 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudDescribeDatasetsRequest.m @@ -0,0 +1,84 @@ +// +// QCloudDescribeDatasetsRequest.m +// QCloudDescribeDatasetsRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDescribeDatasetsRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudDescribeDatasetsRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseJSONSerilizerBlock, + QCloudResponseObjectSerilizerBlock([QCloudDescribeDatasetsResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"get"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [NSURL URLWithString:[NSString stringWithFormat:@"%@://%@.ci.%@.%@",self.runOnService.configuration.endpoint.useHTTPS?@"https":@"http",self.runOnService.configuration.appID, self.regionName?:self.runOnService.configuration.endpoint.regionName, self.runOnService.configuration.endpoint.serviceName]]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:@"application/json" forHTTPHeaderField:@"Accept"]; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"datasets"]; + self.requestData.URIComponents = __pathComponents; + + [self.requestData setQueryStringParamter:@(self.maxresults).stringValue withKey:@"maxresults"]; + if (self.nexttoken) { + [self.requestData setQueryStringParamter:self.nexttoken withKey:@"nexttoken"]; + } + if (self.prefix) { + [self.requestData setQueryStringParamter:self.prefix withKey:@"prefix"]; + } + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudDescribeDatasetsResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudDescribeFileMetaIndexRequest.h b/QCloudCOSXML/Classes/MateData/request/QCloudDescribeFileMetaIndexRequest.h new file mode 100644 index 0000000..0ca48de --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudDescribeFileMetaIndexRequest.h @@ -0,0 +1,81 @@ +// +// QCloudDescribeFileMetaIndexRequest.h +// QCloudDescribeFileMetaIndexRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudDescribeFileMetaIndexResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 查询元数据索引. + + ### 功能描述 + + 获取数据集内已完成索引的一个文件的元数据。. + + 具体请查看 https://cloud.tencent.com/document/product/460/106164. + +### 示例 + + @code + + QCloudDescribeFileMetaIndexRequest * request = [QCloudDescribeFileMetaIndexRequest new]; + request.regionName = @"COS_REGIONNAME"; + // 数据集名称,同一个账户下唯一。;是否必传:true; + request.datasetname = @"数据集名称"; + // 资源标识字段,表示需要建立索引的文件地址,当前仅支持 COS 上的文件,字段规则:cos:///,其中BucketName表示 COS 存储桶名称,ObjectKey 表示文件完整路径,例如:cos://examplebucket-1250000000/test1/img.jpg。 注意: 仅支持本账号内的 COS 文件 不支持 HTTP 开头的地址 需 UrlEncode;是否必传:true; + request.uri = @"cos://facesearch-12500000000"; + + [request setFinishBlock:^(QCloudDescribeFileMetaIndexResponse * outputObject, NSError *error) { + // result:QCloudDescribeFileMetaIndexResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/106164 + }]; + [[QCloudCOSXMLService defaultCOSXML] DescribeFileMetaIndex:request]; + + +*/ + +@interface QCloudDescribeFileMetaIndexRequest : QCloudBizHTTPRequest + +/// 数据集名称,同一个账户下唯一。;是否必传:是 +@property (nonatomic,strong) NSString * datasetname; + +/// 资源标识字段,表示需要建立索引的文件地址,当前仅支持 COS 上的文件,字段规则:cos:///,其中BucketName表示 COS 存储桶名称,ObjectKey 表示文件完整路径,例如:cos://examplebucket-1250000000/test1/img.jpg。 注意: 仅支持本账号内的 COS 文件 不支持 HTTP 开头的地址 需 UrlEncode;是否必传:是 +@property (nonatomic,strong) NSString * uri; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudDescribeFileMetaIndexResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudDescribeFileMetaIndexRequest.m b/QCloudCOSXML/Classes/MateData/request/QCloudDescribeFileMetaIndexRequest.m new file mode 100644 index 0000000..88d0589 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudDescribeFileMetaIndexRequest.m @@ -0,0 +1,83 @@ +// +// QCloudDescribeFileMetaIndexRequest.m +// QCloudDescribeFileMetaIndexRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudDescribeFileMetaIndexRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudDescribeFileMetaIndexRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseJSONSerilizerBlock, + QCloudResponseObjectSerilizerBlock([QCloudDescribeFileMetaIndexResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"get"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [NSURL URLWithString:[NSString stringWithFormat:@"%@://%@.ci.%@.%@",self.runOnService.configuration.endpoint.useHTTPS?@"https":@"http",self.runOnService.configuration.appID, self.regionName?:self.runOnService.configuration.endpoint.regionName, self.runOnService.configuration.endpoint.serviceName]]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:@"application/json" forHTTPHeaderField:@"Accept"]; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"filemeta"]; + self.requestData.URIComponents = __pathComponents; + + if (self.datasetname) { + [self.requestData setQueryStringParamter:self.datasetname withKey:@"datasetname"]; + } + if (self.uri) { + [self.requestData setQueryStringParamter:self.uri withKey:@"uri"]; + } + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudDescribeFileMetaIndexResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudSearchImageRequest.h b/QCloudCOSXML/Classes/MateData/request/QCloudSearchImageRequest.h new file mode 100644 index 0000000..a414212 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudSearchImageRequest.h @@ -0,0 +1,85 @@ +// +// QCloudSearchImageRequest.h +// QCloudSearchImageRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudSearchImageResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 图像检索. + + ### 功能描述 + + 可通过输入自然语言或图片,基于语义对数据集内文件进行图像检索。. + + 具体请查看 https://cloud.tencent.com/document/product/460/106376 + +### 示例 + + @code + + QCloudSearchImageRequest * request = [QCloudSearchImageRequest new]; + request.regionName = @"COS_REGIONNAME"; + request.input = [QCloudSearchImage new]; + // 数据集名称,同一个账户下唯一。;是否必传:是 + request.input.DatasetName = @"ImageSearch001"; + // 指定检索方式为图片或文本,pic 为图片检索,text 为文本检索,默认为 pic。;是否必传:否 + request.input.Mode = @"pic"; + // 资源标识字段,表示需要建立索引的文件地址(Mode 为 pic 时必选)。;是否必传:否 + request.input.URI = @"cos://facesearch-1258726280/huge_base.jpg"; + // 返回相关图片的数量,默认值为10,最大值为100。;是否必传:否 + request.input.Limit = 10; + // 出参 Score(相关图片匹配得分) 中,只有超过 MatchThreshold 值的结果才会返回。默认值为0,推荐值为80。;是否必传:否 + request.input.MatchThreshold = 1; + + [request setFinishBlock:^(QCloudSearchImageResponse * outputObject, NSError *error) { + // result:QCloudSearchImageResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/106376 + }]; + [[QCloudCOSXMLService defaultCOSXML] SearchImage:request]; + + +*/ + +@interface QCloudSearchImageRequest : QCloudBizHTTPRequest + +/// 请求输入参数 +@property (nonatomic,strong)QCloudSearchImage * input; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudSearchImageResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudSearchImageRequest.m b/QCloudCOSXML/Classes/MateData/request/QCloudSearchImageRequest.m new file mode 100644 index 0000000..9fe7337 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudSearchImageRequest.m @@ -0,0 +1,83 @@ +// +// QCloudSearchImageRequest.m +// QCloudSearchImageRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudSearchImageRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudSearchImageRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + QCloudURLFuseWithJSONParamters, + QCloudURLFuseContentMD5Base64StyleHeaders + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseJSONSerilizerBlock, + QCloudResponseObjectSerilizerBlock([QCloudSearchImageResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"post"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [NSURL URLWithString:[NSString stringWithFormat:@"%@://%@.ci.%@.%@",self.runOnService.configuration.endpoint.useHTTPS?@"https":@"http",self.runOnService.configuration.appID, self.regionName?:self.runOnService.configuration.endpoint.regionName, self.runOnService.configuration.endpoint.serviceName]]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:@"application/json" forHTTPHeaderField:@"Accept"]; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"datasetquery"]; + [__pathComponents addObject:@"imagesearch"]; + self.requestData.URIComponents = __pathComponents; + + if (self.input) { + self.requestData.directBody = [self.input qcloud_modelToJSONData]; + } + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudSearchImageResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudUpdateDatasetRequest.h b/QCloudCOSXML/Classes/MateData/request/QCloudUpdateDatasetRequest.h new file mode 100644 index 0000000..8fc9b91 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudUpdateDatasetRequest.h @@ -0,0 +1,81 @@ +// +// QCloudUpdateDatasetRequest.h +// QCloudUpdateDatasetRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudUpdateDatasetResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 更新数据集. + + ### 功能描述 + + 更新一个数据集(Dataset)信息。. + + 具体请查看 https://cloud.tencent.com/document/product/460/106156. + +### 示例 + + @code + + QCloudUpdateDatasetRequest * request = [QCloudUpdateDatasetRequest new]; + request.regionName = @"COS_REGIONNAME"; + request.input = [QCloudUpdateDataset new]; + // 数据集名称,同一个账户下唯一。;是否必传:是 + request.input.DatasetName = @"test"; + // 数据集描述信息。长度为1~256个英文或中文字符,默认值为空。;是否必传:否 + request.input.Description = @"test"; + // 检与数据集关联的检索模板,在建立元数据索引时,后端将根据检索模板来决定采集文件的哪些元数据。 每个检索模板都包含若干个算子,不同的算子表示不同的处理能力,更多信息请参见 [检索模板与算子](https://cloud.tencent.com/document/product/460/106018)。 默认值为空,即不关联检索模板,不进行任何元数据的采集。;是否必传:否 + request.input.TemplateId = @"Official:COSBasicMeta"; + + [request setFinishBlock:^(QCloudUpdateDatasetResponse * outputObject, NSError *error) { + // result:QCloudUpdateDatasetResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/106156 + }]; + [[QCloudCOSXMLService defaultCOSXML] UpdateDataset:request]; + + +*/ + +@interface QCloudUpdateDatasetRequest : QCloudBizHTTPRequest + +/// 请求输入参数 +@property (nonatomic,strong)QCloudUpdateDataset * input; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudUpdateDatasetResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudUpdateDatasetRequest.m b/QCloudCOSXML/Classes/MateData/request/QCloudUpdateDatasetRequest.m new file mode 100644 index 0000000..fffd549 --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudUpdateDatasetRequest.m @@ -0,0 +1,82 @@ +// +// QCloudUpdateDatasetRequest.m +// QCloudUpdateDatasetRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudUpdateDatasetRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudUpdateDatasetRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + QCloudURLFuseWithJSONParamters, + QCloudURLFuseContentMD5Base64StyleHeaders + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseJSONSerilizerBlock, + QCloudResponseObjectSerilizerBlock([QCloudUpdateDatasetResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"put"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [NSURL URLWithString:[NSString stringWithFormat:@"%@://%@.ci.%@.%@",self.runOnService.configuration.endpoint.useHTTPS?@"https":@"http",self.runOnService.configuration.appID, self.regionName?:self.runOnService.configuration.endpoint.regionName, self.runOnService.configuration.endpoint.serviceName]]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:@"application/json" forHTTPHeaderField:@"Accept"]; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"dataset"]; + self.requestData.URIComponents = __pathComponents; + + if (self.input) { + self.requestData.directBody = [self.input qcloud_modelToJSONData]; + } + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudUpdateDatasetResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudUpdateFileMetaIndexRequest.h b/QCloudCOSXML/Classes/MateData/request/QCloudUpdateFileMetaIndexRequest.h new file mode 100644 index 0000000..957673e --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudUpdateFileMetaIndexRequest.h @@ -0,0 +1,91 @@ +// +// QCloudUpdateFileMetaIndexRequest.h +// QCloudUpdateFileMetaIndexRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import +#import +#import "QCloudUpdateFileMetaIndexResponse.h" + +NS_ASSUME_NONNULL_BEGIN +/** + + 更新元数据索引. + + ### 功能描述 + + 更新数据集内已索引的一个文件的部分元数据。 + +并非所有的元数据都允许您自定义更新,在您发起更新请求时需要填写数据集,默认会根据该数据集的算子进行元数据重新提取并更新已存在的索引,此外您也可以更新部分自定义的元数据索引,如CustomTags、CustomId等字段,具体请参考请求参数一节。. + + 具体请查看 https://cloud.tencent.com/document/product/460/106162. + +### 示例 + + @code + + QCloudUpdateFileMetaIndexRequest * request = [QCloudUpdateFileMetaIndexRequest new]; + request.regionName = @"COS_REGIONNAME"; + request.input = [QCloudUpdateFileMetaIndex new]; + // 数据集名称,同一个账户下唯一。;是否必传:是 + request.input.DatasetName = @"test001"; + // 用于建立索引的文件信息。;是否必传:是 + request.input.File = [QCloudUpdateMetaFile new]; + // 自定义ID。该文件索引到数据集后,作为该行元数据的属性存储,用于和您的业务系统进行关联、对应。您可以根据业务需求传入该值,例如将某个URI关联到您系统内的某个ID。推荐传入全局唯一的值。在查询时,该字段支持前缀查询和排序,详情请见[字段和操作符的支持列表](https://cloud.tencent.com/document/product/460/106154)。 ;是否必传:否 + request.input.File.CustomId = @"001"; + // 自定义标签。您可以根据业务需要自定义添加标签键值对信息,用于在查询时可以据此为筛选项进行检索,详情请见[字段和操作符的支持列表](https://cloud.tencent.com/document/product/460/106154)。 ;是否必传:否 + request.input.File.CustomLabels = [object Object]; + // 可选项,文件媒体类型,枚举值: image:图片。 other:其他。 document:文档。 archive:压缩包。 video:视频。 audio:音频。 ;是否必传:否 + request.input.File.MediaType = @"image"; + // 可选项,文件内容类型(MIME Type),如image/jpeg。 ;是否必传:否 + request.input.File.ContentType = @"image/jpeg"; + // 资源标识字段,表示需要建立索引的文件地址,当前仅支持COS上的文件,字段规则:cos:///,其中BucketName表示COS存储桶名称,ObjectKey表示文件完整路径,例如:cos://examplebucket-1250000000/test1/img.jpg。 注意: 1、仅支持本账号内的COS文件 2、不支持HTTP开头的地址;是否必传:是 + request.input.File.URI = @"cos://examplebucket-1250000000/test1/img.jpg"; + + [request setFinishBlock:^(QCloudUpdateFileMetaIndexResponse * outputObject, NSError *error) { + // result:QCloudUpdateFileMetaIndexResponse 包含所有的响应; + // 具体查看代码注释或api文档:https://cloud.tencent.com/document/product/460/106162 + }]; + [[QCloudCOSXMLService defaultCOSXML] UpdateFileMetaIndex:request]; + + +*/ + +@interface QCloudUpdateFileMetaIndexRequest : QCloudBizHTTPRequest + +/// 请求输入参数 +@property (nonatomic,strong)QCloudUpdateFileMetaIndex * input; + +- (void)setFinishBlock:(void (^_Nullable)( QCloudUpdateFileMetaIndexResponse * _Nullable result, NSError *_Nullable error))finishBlock; + +@end + + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/MateData/request/QCloudUpdateFileMetaIndexRequest.m b/QCloudCOSXML/Classes/MateData/request/QCloudUpdateFileMetaIndexRequest.m new file mode 100644 index 0000000..b3b225c --- /dev/null +++ b/QCloudCOSXML/Classes/MateData/request/QCloudUpdateFileMetaIndexRequest.m @@ -0,0 +1,82 @@ +// +// QCloudUpdateFileMetaIndexRequest.m +// QCloudUpdateFileMetaIndexRequest +// +// Created by tencent +// Copyright (c) 2015年 tencent. All rights reserved. +// +// ██████╗ ██████╗██╗ ██████╗ ██╗ ██╗██████╗ ████████╗███████╗██████╗ ███╗ ███╗██╗███╗ ██╗ █████╗ ██╗ ██╗ █████╗ +// ██████╗ +// ██╔═══██╗██╔════╝██║ ██╔═══██╗██║ ██║██╔══██╗ ╚══██╔══╝██╔════╝██╔══██╗████╗ ████║██║████╗ ██║██╔══██╗██║ ██║ ██╔══██╗██╔══██╗ +// ██║ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ █████╗ ██████╔╝██╔████╔██║██║██╔██╗ ██║███████║██║ ██║ ███████║██████╔╝ +// ██║▄▄ ██║██║ ██║ ██║ ██║██║ ██║██║ ██║ ██║ ██╔══╝ ██╔══██╗██║╚██╔╝██║██║██║╚██╗██║██╔══██║██║ ██║ ██╔══██║██╔══██╗ +// ╚██████╔╝╚██████╗███████╗╚██████╔╝╚██████╔╝██████╔╝ ██║ ███████╗██║ ██║██║ ╚═╝ ██║██║██║ ╚████║██║ ██║███████╗ ███████╗██║ +// ██║██████╔╝ +// ╚══▀▀═╝ ╚═════╝╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝ ╚═╝╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝ ╚══════╝╚═╝ ╚═╝╚═════╝ +// +// +// _ __ _ _ +// (_) / _| | | | | +// ___ ___ _ ____ ___ ___ ___ | |_ ___ _ __ __| | _____ _____| | ___ _ __ ___ _ +// __ ___ +// / __|/ _ \ '__\ \ / / |/ __/ _ \ | _/ _ \| '__| / _` |/ _ \ \ / / _ \ |/ _ \| '_ \ / _ \ +// '__/ __| +// \__ \ __/ | \ V /| | (_| __/ | || (_) | | | (_| | __/\ V / __/ | (_) | |_) | __/ +// | \__ +// |___/\___|_| \_/ |_|\___\___| |_| \___/|_| \__,_|\___| \_/ \___|_|\___/| .__/ +// \___|_| |___/ +// ______ ______ ______ ______ ______ ______ ______ ______ | | +// |______|______|______|______|______|______|______|______| |_| +// + +#import "QCloudUpdateFileMetaIndexRequest.h" +#import +#import +#import + +NS_ASSUME_NONNULL_BEGIN +@implementation QCloudUpdateFileMetaIndexRequest + +- (void)configureReuqestSerializer:(QCloudRequestSerializer *)requestSerializer responseSerializer:(QCloudResponseSerializer *)responseSerializer { + NSArray *customRequestSerilizers = @[ + QCloudURLFuseURIMethodASURLParamters, + QCloudURLFuseWithJSONParamters, + QCloudURLFuseContentMD5Base64StyleHeaders + ]; + NSArray *responseSerializers = @[ + QCloudAcceptRespnseCodeBlock([NSSet setWithObjects:@(200), @(201), @(202), @(203), @(204), @(205), @(206), @(207), @(208), @(226), nil], nil), + QCloudResponseJSONSerilizerBlock, + QCloudResponseObjectSerilizerBlock([QCloudUpdateFileMetaIndexResponse class]) + ]; + [requestSerializer setSerializerBlocks:customRequestSerilizers]; + [responseSerializer setSerializerBlocks:responseSerializers]; + requestSerializer.HTTPMethod = @"put"; +} + +- (BOOL)buildRequestData:(NSError *__autoreleasing *)error { + + if (![super buildRequestData:error]) {return NO;} + + NSURL *__serverURL = [NSURL URLWithString:[NSString stringWithFormat:@"%@://%@.ci.%@.%@",self.runOnService.configuration.endpoint.useHTTPS?@"https":@"http",self.runOnService.configuration.appID, self.regionName?:self.runOnService.configuration.endpoint.regionName, self.runOnService.configuration.endpoint.serviceName]]; + self.requestData.serverURL = __serverURL.absoluteString; + + [self.requestData setValue:@"application/json" forHTTPHeaderField:@"Accept"]; + + [self.requestData setValue:__serverURL.host forHTTPHeaderField:@"Host"]; + + NSMutableArray *__pathComponents = [NSMutableArray arrayWithArray:self.requestData.URIComponents]; + [__pathComponents addObject:@"filemeta"]; + self.requestData.URIComponents = __pathComponents; + + if (self.input) { + self.requestData.directBody = [self.input qcloud_modelToJSONData]; + } + return YES; +} +- (void)setFinishBlock:(void (^_Nullable)( QCloudUpdateFileMetaIndexResponse * _Nullable result, NSError *_Nullable error))finishBlock{ + [super setFinishBlock:finishBlock]; +} +@end + + +NS_ASSUME_NONNULL_END diff --git a/QCloudCOSXML/Classes/QCloudCOSXMLVersion.h b/QCloudCOSXML/Classes/QCloudCOSXMLVersion.h index 5075208..6357529 100644 --- a/QCloudCOSXML/Classes/QCloudCOSXMLVersion.h +++ b/QCloudCOSXML/Classes/QCloudCOSXMLVersion.h @@ -5,7 +5,7 @@ #ifndef QCloudCOSXMLModuleVersion_h #define QCloudCOSXMLModuleVersion_h -#define QCloudCOSXMLModuleVersionNumber 604000 +#define QCloudCOSXMLModuleVersionNumber 604001 //dependency diff --git a/QCloudCOSXML/Classes/QCloudCOSXMLVersion.m b/QCloudCOSXML/Classes/QCloudCOSXMLVersion.m index 0ae338b..a6966f4 100644 --- a/QCloudCOSXML/Classes/QCloudCOSXMLVersion.m +++ b/QCloudCOSXML/Classes/QCloudCOSXMLVersion.m @@ -1,5 +1,5 @@ #import "QCloudCOSXMLVersion.h" -NSString * const QCloudCOSXMLModuleVersion = @"6.4.0"; +NSString * const QCloudCOSXMLModuleVersion = @"6.4.1"; NSString * const QCloudCOSXMLModuleName = @"QCloudCOSXML"; @interface QCloudQCloudCOSXMLLoad : NSObject @end diff --git a/QCloudCOSXML/Classes/Transfer/request/QCloudCOSXMLUploadObjectRequest.m b/QCloudCOSXML/Classes/Transfer/request/QCloudCOSXMLUploadObjectRequest.m index c9fe06c..3d87b73 100644 --- a/QCloudCOSXML/Classes/Transfer/request/QCloudCOSXMLUploadObjectRequest.m +++ b/QCloudCOSXML/Classes/Transfer/request/QCloudCOSXMLUploadObjectRequest.m @@ -485,15 +485,17 @@ - (void)uploadOffsetBodys:(NSArray *)allParts { _queueSource = dispatch_source_create(DISPATCH_SOURCE_TYPE_DATA_ADD, 0, 0, dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_HIGH, 0)); __block int totalComplete = 0; dispatch_source_set_event_handler(_queueSource, ^{ - NSUInteger value = dispatch_source_get_data(weakSelf.queueSource); - @synchronized(weakSelf) { - totalComplete += value; - } - if (totalComplete == allParts.count) { - if (NULL != weakSelf.queueSource) { - dispatch_source_cancel(weakSelf.queueSource); + if (weakSelf.queueSource) { + NSUInteger value = dispatch_source_get_data(weakSelf.queueSource); + @synchronized(weakSelf) { + totalComplete += value; + } + if (totalComplete == allParts.count) { + if (NULL != weakSelf.queueSource) { + dispatch_source_cancel(weakSelf.queueSource); + } + [weakSelf finishUpload:weakSelf.uploadId]; } - [weakSelf finishUpload:weakSelf.uploadId]; } }); dispatch_resume(_queueSource); diff --git a/QCloudCOSXMLDemo.xcworkspace/xcuserdata/garenwang.xcuserdatad/UserInterfaceState.xcuserstate b/QCloudCOSXMLDemo.xcworkspace/xcuserdata/garenwang.xcuserdatad/UserInterfaceState.xcuserstate index bb831e7..7a002d8 100644 Binary files a/QCloudCOSXMLDemo.xcworkspace/xcuserdata/garenwang.xcuserdatad/UserInterfaceState.xcuserstate and b/QCloudCOSXMLDemo.xcworkspace/xcuserdata/garenwang.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/QCloudCore.podspec b/QCloudCore.podspec index fefffc4..56a15b3 100644 --- a/QCloudCore.podspec +++ b/QCloudCore.podspec @@ -10,7 +10,7 @@ Pod::Spec.new do |s| s.name = "QCloudCore" -s.version = "6.4.0" +s.version = "6.4.1" @@ -44,7 +44,7 @@ QCloudCore--腾讯云iOS-SDK Foundation。提供腾讯云iOS相关SDK的基础 default.ios.deployment_target = '9.0' default.osx.deployment_target = "10.12" default.source_files = 'QCloudCore/Classes/Base/**/*' - default.dependency "QCloudTrack/Beacon","6.4.0" + default.dependency "QCloudTrack/Beacon","6.4.1" end s.subspec 'WithoutMTA' do |withoutMTA| diff --git a/QCloudCore/Classes/Base/QCLOUDRestNet/CoreRequest/QCloudAbstractRequest.h b/QCloudCore/Classes/Base/QCLOUDRestNet/CoreRequest/QCloudAbstractRequest.h index f6999c4..124386f 100644 --- a/QCloudCore/Classes/Base/QCLOUDRestNet/CoreRequest/QCloudAbstractRequest.h +++ b/QCloudCore/Classes/Base/QCLOUDRestNet/CoreRequest/QCloudAbstractRequest.h @@ -9,6 +9,7 @@ #import #import "QCloudHTTPRequestDelegate.h" #import "QCloudHttpMetrics.h" +#import "QCloudCredential.h" typedef double QCloudAbstractRequestPriority; #define QCloudAbstractRequestPriorityHigh 3.0 @@ -42,6 +43,9 @@ typedef void (^QCloudRequestDownProcessWithDataBlock)(int64_t bytesDownload, int 用于业务中携带与request关联的参数,不参与SDK内部逻辑与网络请求; */ @property (nonatomic, strong ,nullable) NSDictionary * payload; + + +@property (nonatomic, strong, nullable) QCloudCredential * credential; /** 协议执行结果向外通知的委托(delegate)主要包括成功和失败两种情况。与Block方式并存,当两者都设置的时候都会通知。 */ diff --git a/QCloudCore/Classes/Base/QCLOUDRestNet/CoreRequest/QCloudAbstractRequest.m b/QCloudCore/Classes/Base/QCLOUDRestNet/CoreRequest/QCloudAbstractRequest.m index e5dc270..c4b23d6 100644 --- a/QCloudCore/Classes/Base/QCLOUDRestNet/CoreRequest/QCloudAbstractRequest.m +++ b/QCloudCore/Classes/Base/QCLOUDRestNet/CoreRequest/QCloudAbstractRequest.m @@ -180,6 +180,22 @@ - (void)waitForComplete { } [self.condition unlock]; } + +- (void)setCredential:(QCloudCredential *)credential{ + + NSMutableDictionary * _payload = self.payload.mutableCopy; + if (!_payload) { + _payload = [NSMutableDictionary new]; + } + if (credential) { + [_payload setObject:credential forKey:@"QCloudCredential"]; + } + self.payload = _payload.copy; +} + +- (QCloudCredential *)credential{ + return [self.payload objectForKey:@"QCloudCredential"]; +} - (void)configTaskResume { } @end diff --git a/QCloudCore/Classes/Base/QCLOUDRestNet/SessionSupport/QCloudHTTPSessionManager.m b/QCloudCore/Classes/Base/QCLOUDRestNet/SessionSupport/QCloudHTTPSessionManager.m index a0d589b..6b6034d 100644 --- a/QCloudCore/Classes/Base/QCLOUDRestNet/SessionSupport/QCloudHTTPSessionManager.m +++ b/QCloudCore/Classes/Base/QCLOUDRestNet/SessionSupport/QCloudHTTPSessionManager.m @@ -313,7 +313,7 @@ - (void)URLSession:(NSURLSession *)session task:(NSURLSessionTask *)task didComp object:nil userInfo:@{ @"url" : task.originalRequest.URL ? task.originalRequest.URL - : [NSURL URLWithString:@"http://nullurl.error.com.tencent.qcloud.network"] + : [NSURL URLWithString:@"https://nullurl.error.com.tencent.qcloud.network"] }]; diff --git a/QCloudCore/Classes/Base/QCloudClientBase/Request/QCloudBizHTTPRequest.h b/QCloudCore/Classes/Base/QCloudClientBase/Request/QCloudBizHTTPRequest.h index 5ea6a89..9f05a7f 100644 --- a/QCloudCore/Classes/Base/QCloudClientBase/Request/QCloudBizHTTPRequest.h +++ b/QCloudCore/Classes/Base/QCloudClientBase/Request/QCloudBizHTTPRequest.h @@ -28,6 +28,7 @@ extern _Nonnull QCloudResponseSerializerBlock QCloudResponseCOSNormalRSPSerilize @class QCloudServiceConfiguration; @interface QCloudBizHTTPRequest : QCloudHTTPRequest +// 若 request中设置了 credential ,则不回调该代理方法。 @property (nonatomic, strong) id signatureProvider; diff --git a/QCloudCore/Classes/Base/QCloudClientBase/Request/QCloudBizHTTPRequest.m b/QCloudCore/Classes/Base/QCloudClientBase/Request/QCloudBizHTTPRequest.m index a34b1be..4e1c930 100644 --- a/QCloudCore/Classes/Base/QCloudClientBase/Request/QCloudBizHTTPRequest.m +++ b/QCloudCore/Classes/Base/QCloudClientBase/Request/QCloudBizHTTPRequest.m @@ -19,6 +19,7 @@ #import #import "NSObject+QCloudModelTool.h" #import "QCloudLogger.h" +#import "QCloudAuthentationV5Creator.h" NS_ASSUME_NONNULL_BEGIN QCloudResponseSerializerBlock QCloudResponseObjectSerilizerBlock(Class modelClass) { @@ -124,15 +125,36 @@ - (QCloudSignatureFields *)signatureFields { - (BOOL)prepareInvokeURLRequest:(NSMutableURLRequest *)urlRequest error:(NSError *__autoreleasing *)error { + if (self.credential && self.credential.secretID.length > 0 && self.credential.secretKey.length > 0) { + QCloudAuthentationV5Creator *creator = [[QCloudAuthentationV5Creator alloc] initWithCredential:self.credential]; + QCloudSignature *signature = [creator signatureForData:(NSMutableURLRequest *)urlRequest]; + if (!self.isSignedInURL) { + [urlRequest setValue:signature.signature forHTTPHeaderField:@"Authorization"]; + } else { + NSString *urlStr; + NSRange rangeOfQ = [urlStr rangeOfString:@"?"]; + if (rangeOfQ.location == NSNotFound) { + urlStr = [NSString stringWithFormat:@"%@?%@", urlRequest.URL.absoluteString, signature.signature]; + } else { + urlStr = [NSString stringWithFormat:@"%@&%@", urlRequest.URL.absoluteString, signature.signature]; + } + if (signature.token) { + urlStr = [NSString stringWithFormat:@"%@&x-cos-security-token=%@", urlStr, signature.token]; + } + urlRequest.URL = [[NSURL URLWithString:urlStr] copy]; + } + return YES; + } + if(!self.signatureProvider){ return YES; } - // NSAssert(self.runOnService, @"RUN ON SERVICE is nil%@", self.runOnService); self.semaphore = dispatch_semaphore_create(0); self.semp_flag = 1; __block NSError *localError; __block BOOL isSigned; + dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_HIGH, 0), ^{ [self.signatureProvider signatureWithFields:self.signatureFields diff --git a/QCloudCore/Classes/Base/QCloudCoreVersion.h b/QCloudCore/Classes/Base/QCloudCoreVersion.h index 6d3bd52..26ccc98 100644 --- a/QCloudCore/Classes/Base/QCloudCoreVersion.h +++ b/QCloudCore/Classes/Base/QCloudCoreVersion.h @@ -5,7 +5,7 @@ #ifndef QCloudCoreModuleVersion_h #define QCloudCoreModuleVersion_h -#define QCloudCoreModuleVersionNumber 604000 +#define QCloudCoreModuleVersionNumber 604001 //dependency diff --git a/QCloudCore/Classes/Base/QCloudCoreVersion.m b/QCloudCore/Classes/Base/QCloudCoreVersion.m index c0853c0..dfadae4 100644 --- a/QCloudCore/Classes/Base/QCloudCoreVersion.m +++ b/QCloudCore/Classes/Base/QCloudCoreVersion.m @@ -1,5 +1,5 @@ #import "QCloudCoreVersion.h" -NSString * const QCloudCoreModuleVersion = @"6.4.0"; +NSString * const QCloudCoreModuleVersion = @"6.4.1"; NSString * const QCloudCoreModuleName = @"QCloudCore"; @interface QCloudQCloudCoreLoad : NSObject @end diff --git a/QCloudTrack.podspec b/QCloudTrack.podspec index a16366e..2e7d11b 100644 --- a/QCloudTrack.podspec +++ b/QCloudTrack.podspec @@ -8,7 +8,7 @@ Pod::Spec.new do |s| s.name = "QCloudTrack" -s.version = "6.4.0" +s.version = "6.4.1" s.summary = "QCloudTrack 腾讯云iOS-SDK组件" # This description is used to generate tags and improve search results. diff --git a/QCloudTrack/Classes/Cls/QCloudCLSTrackService.m b/QCloudTrack/Classes/Cls/QCloudCLSTrackService.m index f422db6..f81046e 100644 --- a/QCloudTrack/Classes/Cls/QCloudCLSTrackService.m +++ b/QCloudTrack/Classes/Cls/QCloudCLSTrackService.m @@ -36,7 +36,18 @@ -(void)setupCredentialsRefreshBlock:(QCloudCredentialRefreshBlock)refreshBlock{ -(void)setupCLSSDK{ - LogProducerConfig * config = [[LogProducerConfig alloc]initWithCoreInfo:self.endPoint accessKeyID:self.credentialProvider.getCredentials.secretId accessKeySecret:self.credentialProvider.getCredentials.secretKey securityToken:self.credentialProvider.getCredentials.token]; + + NSString *secretId = self.credentialProvider.getCredentials.secretId; + if (!secretId) { + secretId = @""; + } + + NSString *secretKey = self.credentialProvider.getCredentials.secretKey; + if (!secretKey) { + secretKey = @""; + } + + LogProducerConfig * config = [[LogProducerConfig alloc]initWithCoreInfo:self.endPoint accessKeyID:secretId accessKeySecret:secretKey securityToken:self.credentialProvider.getCredentials.token]; [config SetTopic:self.topicId]; [config SetPackageLogBytes:1024*1024]; [config SetPackageLogCount:1024]; diff --git a/QCloudTrack/Classes/Default/QCloudTrackService.m b/QCloudTrack/Classes/Default/QCloudTrackService.m index 2396de8..8d964af 100644 --- a/QCloudTrack/Classes/Default/QCloudTrackService.m +++ b/QCloudTrack/Classes/Default/QCloudTrackService.m @@ -86,7 +86,7 @@ -(NSDictionary *)getCommonParams{ [commonParams setObject:@"" forKey:@"os_version"]; #endif [commonParams setObject:[QCloudTrackNetworkUtils single].getCurrentLocalIP ?:@"" forKey:@"client_local_ip"]; - [commonParams setObject:[QCloudTrackNetworkUtils single].isProxy?@"true":@"false" forKey:@"client_proxy"]; + [commonParams setObject:[QCloudTrackNetworkUtils single].isProxyUsed?@"true":@"false" forKey:@"client_proxy"]; [commonParams setObject:[QCloudTrackNetworkUtils single].getNetWorkType ?:@"" forKey:@"network_type"]; return commonParams.copy; diff --git a/QCloudTrack/Classes/QCloudTrackVersion.h b/QCloudTrack/Classes/QCloudTrackVersion.h index a2e13ef..4996885 100644 --- a/QCloudTrack/Classes/QCloudTrackVersion.h +++ b/QCloudTrack/Classes/QCloudTrackVersion.h @@ -5,7 +5,7 @@ #ifndef QCloudTrackModuleVersion_h #define QCloudTrackModuleVersion_h -#define QCloudTrackModuleVersionNumber 604000 +#define QCloudTrackModuleVersionNumber 604001 //dependency diff --git a/QCloudTrack/Classes/QCloudTrackVersion.m b/QCloudTrack/Classes/QCloudTrackVersion.m index f96388c..1d8ea78 100644 --- a/QCloudTrack/Classes/QCloudTrackVersion.m +++ b/QCloudTrack/Classes/QCloudTrackVersion.m @@ -1,5 +1,5 @@ #import "QCloudTrackVersion.h" -NSString * const QCloudTrackModuleVersion = @"6.4.0"; +NSString * const QCloudTrackModuleVersion = @"6.4.1"; NSString * const QCloudTrackModuleName = @"QCloudTrack"; @interface QCloudQCloudTrackLoad : NSObject @end