C# 클래스 Qiniu.Storage.UploadManager

上传管理器,可以通过该上传管理器自动判断上传的内容是 采用表单上传还是分片上传。 对于二进制数据和文件流,目前仅支持表单上传 对于沙盒文件,目前支持以表单方式和分片方式上传
파일 보기 프로젝트 열기: qiniu/csharp-sdk 1 사용 예제들

공개 메소드들

메소드 설명
UploadManager ( ) : System

默认上传管理器

UploadManager ( ResumeRecorder recorder, KeyGenerator generator ) : System

以指定的分片上传进度记录器和分片上传记录文件名构建上传管理器 可以指定这两个参数来使分片上传支持断点续传功能

uploadData ( byte data, string key, string token, Qiniu.Storage.UploadOptions uploadOptions, UpCompletionHandler upCompletionHandler ) : void
uploadFile ( string filePath, string key, string token, Qiniu.Storage.UploadOptions uploadOptions, UpCompletionHandler upCompletionHandler ) : void
uploadStream ( Stream stream, string key, string token, Qiniu.Storage.UploadOptions uploadOptions, UpCompletionHandler upCompletionHandler ) : void

비공개 메소드들

메소드 설명
DefaultUpCompletionHandler ( string key, Qiniu.Http.ResponseInfo respInfo, string respJson ) : void

메소드 상세

UploadManager() 공개 메소드

默认上传管理器
public UploadManager ( ) : System
리턴 System

UploadManager() 공개 메소드

以指定的分片上传进度记录器和分片上传记录文件名构建上传管理器 可以指定这两个参数来使分片上传支持断点续传功能
public UploadManager ( ResumeRecorder recorder, KeyGenerator generator ) : System
recorder Qiniu.Storage.Persistent.ResumeRecorder 分片上传进度记录器
generator KeyGenerator 分片上传进度记录文件名
리턴 System

uploadData() 공개 메소드

public uploadData ( byte data, string key, string token, Qiniu.Storage.UploadOptions uploadOptions, UpCompletionHandler upCompletionHandler ) : void
data byte
key string
token string
uploadOptions Qiniu.Storage.UploadOptions
upCompletionHandler UpCompletionHandler
리턴 void

uploadFile() 공개 메소드

public uploadFile ( string filePath, string key, string token, Qiniu.Storage.UploadOptions uploadOptions, UpCompletionHandler upCompletionHandler ) : void
filePath string
key string
token string
uploadOptions Qiniu.Storage.UploadOptions
upCompletionHandler UpCompletionHandler
리턴 void

uploadStream() 공개 메소드

public uploadStream ( Stream stream, string key, string token, Qiniu.Storage.UploadOptions uploadOptions, UpCompletionHandler upCompletionHandler ) : void
stream Stream
key string
token string
uploadOptions Qiniu.Storage.UploadOptions
upCompletionHandler UpCompletionHandler
리턴 void