BDVideoUploaderClient class
- Inheritance
-
- Object
- NativeClass
- BDVideoUploaderClient
- Implementers
Methods
-
close()
→ FutureOr<void>
-
{zh}
@brief 结束上传,并销毁上传实例(不可恢复)。
@notes 当不需要再次进行上传操作时,务必调用该函数进行上传实例的销毁,否则会导致内存泄露。
-
destroy()
→ void
-
inherited
-
initWithFilePath(NSString filePath)
→ FutureOr<BDVideoUploaderClient>
-
{zh}
@brief 初始化上传实例。
@param filePath 需要上传的视频的路径。
@return 上传实例。
-
nativeCall<T>(String method, [List? args, NativeMethodMeta? meta])
→ Future<T>
-
Call instance method
inherited
-
noSuchMethod(Invocation invocation)
→ dynamic
-
Invoked when a nonexistent method or property is accessed.
inherited
-
sendInstanceGet<T>(String property)
→ Future<T>
-
Get instance property
inherited
-
sendInstanceSet(String property, dynamic value)
→ Future<void>
-
Set instance property
inherited
-
setAuthorizationParameter(NSDictionary parameter)
→ FutureOr<void>
-
{zh}
@brief 设置鉴权。
@param parameter 鉴权参数。
@brief 鉴权参数包括:
BDFileUploadAccessKey : accessKey
BDFileUploadSecretKey : secretKey
BDFileUploadSessionToken : sessionToken
BDFileUploadSpace : spaceName
-
setClassificationId(NSInteger classificationId)
→ FutureOr<void>
-
{zh}
@brief 设置分类 ID,从而对视频进行分类。
@param classificationId 需要设置的分类 ID。
@notes 素材不支持分类。
-
{zh}
@brief 设置自定义 http header。
@param parameter 需要设置的 header。
-
setDescription(NSString description)
→ FutureOr<void>
-
{zh}
@brief 设置上传素材的描述信息。
@param description 需要设置的素材的描述信息。
@notes 素材上传时独有参数。
-
setFileExtension(NSString fileExtension)
→ FutureOr<void>
-
{zh}
@brief 设置文件路径后缀。
@param fileExtension 需要设置的文件路径后缀。
@notes 后缀需要以 '.' 开头,比如 ".mp4"。
-
setFileName(NSString fileName)
→ FutureOr<void>
-
-
setFilePrefix(NSString filePrefix)
→ FutureOr<void>
-
{zh}
@brief 设置文件路径前缀。
@param filePrefix 需要设置的文件路径前缀。
@notes 前缀需要以 '/' 结尾。
-
setFlushUploadMode(BDUploadFlushUploadMode mode)
→ FutureOr<void>
-
{zh}
@brief 设置覆盖上传模式。
@param mode BDUploadFlushUploadMode 枚举值,详见 BDUploadFlushUploadMode{@link #BDUploadFlushUploadMode}。
-
setFormat(NSString format)
→ FutureOr<void>
-
{zh}
@brief 设置上传素材的格式。
@param format 需要设置的素材的格式。
@notes 素材上传时独有参数;多个标签可用逗号隔开。
-
setGetMetaMode(BDVideoUploadGetMetaMode mode)
→ FutureOr<void>
-
{zh}
@brief 设置抽取 meta 的模式。
@param mode 需要设置模式,详见 BDVideoUploadGetMetaMode{@link #BDVideoUploadGetMetaMode}。
-
setOptionInfo(NSDictionary optionInfo)
→ FutureOr<void>
-
{zh}
@brief 设置上传额外参数。
@param optionInfo 需要设置的 kv 形式的额外参数。
@notes 传入的所有键值对会被透传到服务端。
-
setRequestParameter(NSDictionary parameter)
→ FutureOr<void>
-
{zh}
@brief 设置自定义请求参数。
@param parameter 需要设置的请求参数。
@notes 参数说明:
key type Describe
BDFileUploadFileType NSString 上传文件类型,比如 "media"
BDFileUploadTraceId NSString 上传跟踪标识,可将该次上传于业务行为进行关联
BDFileUploadCustomedParameter NSString 需要携带的自定义参数
-
setTags(NSString tags)
→ FutureOr<void>
-
{zh}
@brief 设置上传素材的标签。
@param tags 需要设置的素材的标签。
@notes 素材上传时独有参数;多个标签可用逗号隔开。
-
setTemplateId(NSString templateId)
→ FutureOr<void>
-
{zh}
@brief 设置工作流 ID。
@param templateId 需要设置的工作流 ID。
-
setTitle(NSString title)
→ FutureOr<void>
-
{zh}
@brief 设置上传素材的标题。
@param title 需要设置的素材的标题。
@notes 素材上传时独有参数。
-
setUploadConfig(NSDictionary config)
→ FutureOr<void>
-
{zh}
@brief 设置上传的配置策略。
@param config 需要配置的上传策略。
@notes
键值 类型 描述 是否必须
BDFileUploadSliceRetryCount NSNumber(NSInteger) 分片失败重试次数 NO
BDFileUploadFileRetryCount NSNumber(NSInteger) 文件失败重试次数 NO
BDFileUploadTranTimeOutUnit NSNumber(NSInteger) socket 单次读写超时时间 NO
BDFileUploadSliceSize NSNumber(NSInteger) 分片的大小 NO
BDFileUploadSocketNum NSNumber(NSInteger) 并行分片上传线程数 NO
BDFileUploadMaxFailTimes NSNumber(NSInteger) 最大建联失败时间 NO
BDFileUploadAliveMaxFailTime NSNumber(NSInteger) 复用连接情况下最大超时时间 NO
BDFileUploadTcpOpenTimeOutMilliSec NSNumber(NSInteger) tcp 建联超时时间 NO
BDFileUploadRWTimeout NSNumber(NSInteger) socket 读写超时时间 NO
BDFileUploadHttpsEnable NSNumber(BOOL) 是否开启 https NO
BDFileUploadDiskResumeOption NSNumber(NSInteger) 是否开启断点续传功能 NO
-
setVideoHostName(NSString hostName)
→ FutureOr<void>
-
{zh}
@brief 设置 apply 阶段的 host。
@param hostName 需要设置的 host。
-
setVideoRegionName(NSString regionName)
→ FutureOr<void>
-
{zh}
@brief 设置点播视频上传实例的 region。
@param regionName 需要设置的 region。
-
setVideoSceneTag(NSString sceneTag)
→ FutureOr<void>
-
{zh}
@brief 设置场景 tag。
@param sceneTag 需要设置的场景 tag。
-
start()
→ FutureOr<void>
-
{zh}
@brief 开始上传。
-
stop()
→ FutureOr<void>
-
{zh}
@brief 暂停上传。
-
toString()
→ String
-
A string representation of this object.
inherited
-
updateResource(NativeResource resource)
→ void
-
inherited