/GCQiniuUploadManager

provide simple interfaces to create token,upload file and upload files 创建七牛token及实现上传文件

Primary LanguageObjective-C

GCQiniuUploadManager

Introduction

It provide simple interfaces to create token,upload file and upload files

how to use

1.register with your scope, access key and secret key and create token in your AppDelegate.m

[[CJQiniuUploadManager sharedInstance] registerWithScope:CJQiNiuScope
                                                   accessKey:CJQiNiuAccessKey
                                                   secretKey:CJQiNiuSecretKey];
[[CJQiniuUploadManager sharedInstance] createToken];

2.you can upload single data

- (void)uploadData:(NSData *)data
          progress:(UploadProgressHandler)progress
        completion:(UploadDataCompletion)completion;

3.you can also upload multiple data

- (void)uploadDatas:(NSArray<NSData *> *)datas
           progress:(UploadProgressHandler)progress
  oneTaskCompletion:(UploadDataCompletion)oneTaskCompletion
 allTasksCompletion:(UploadAllTasksCompletion)allTasksCompletion;

4.you can set upload token live time,it default is 5 days

@property (nonatomic, assign) NSInteger liveTime;