Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for sizeMapper (1.13 sec)

  1. okhttp/src/commonJvmAndroid/kotlin/okhttp3/ResponseBody.kt

        consumer: (BufferedSource) -> T,
        sizeMapper: (T) -> Int,
      ): T {
        val contentLength = contentLength()
        if (contentLength > Int.MAX_VALUE) {
          throw IOException("Cannot buffer entire body for content length: $contentLength")
        }
    
        val bytes = source().use(consumer)
        val size = sizeMapper(bytes)
        if (contentLength != -1L && contentLength != size.toLong()) {
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Tue May 27 14:51:25 UTC 2025
    - 11.6K bytes
    - Viewed (0)
Back to top