标签: fast-android-networking

上传视频时出现问题:流已重置:NO_ERROR

我正在开发一个使用 TUS 方法将视频上传到 Vimeo 的应用程序。

我为 Fast Android Networking 编写了一个简单的包装器,用于上传视频文件的每个部分。

fun patch(
    destination: RequestDestination = RequestDestination.Api,
    url: String,
    headers: Map<String, Any> = mapOf(),
    body: ByteArray? = null,
    contentType: String? = null,
    priority: Priority = Priority.MEDIUM,
    jsonRequest: Boolean = true,
    success: (Any?) -> Unit,
    failure: (ANError?) -> Unit
) {
    val requestUrlString = getFullUrl(destination, url) // Determines the destination URL, is working correctly
    val request = AndroidNetworking.patch(requestUrlString)
    setRequestAttributes(request, headers, destination, priority) // Adds the request params, headers, etc to the request, …
Run Code Online (Sandbox Code Playgroud)

android kotlin okhttp fast-android-networking

6
推荐指数
2
解决办法
9077
查看次数

标签 统计

android ×1

fast-android-networking ×1

kotlin ×1

okhttp ×1