Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 29 of 29 for Kuper (0.14 sec)

  1. okhttp/src/test/java/okhttp3/OkHttpClientTest.kt

            override fun contains(element: Protocol?): Boolean {
              if (element == null) throw NullPointerException()
              return super.contains(element)
            }
    
            override fun indexOf(element: Protocol?): Int {
              if (element == null) throw NullPointerException()
              return super.indexOf(element)
            }
          } as List<Protocol>
        val client =
          OkHttpClient.Builder()
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sun Mar 31 17:16:15 GMT 2024
    - 13.2K bytes
    - Viewed (0)
  2. samples/guide/src/main/java/okhttp3/recipes/Progress.java

          return new ForwardingSource(source) {
            long totalBytesRead = 0L;
    
            @Override public long read(Buffer sink, long byteCount) throws IOException {
              long bytesRead = super.read(sink, byteCount);
              // read() returns the number of bytes read, or -1 if this source is exhausted.
              totalBytesRead += bytesRead != -1 ? bytesRead : 0;
    Java
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Jan 12 03:31:36 GMT 2019
    - 3.9K bytes
    - Viewed (0)
  3. okhttp/src/main/kotlin/okhttp3/internal/cache/DiskLruCache.kt

          override fun sink(
            file: Path,
            mustCreate: Boolean,
          ): Sink {
            file.parent?.let {
              createDirectories(it)
            }
            return super.sink(file, mustCreate)
          }
        }
    
      /** The maximum number of bytes that this cache should use to store its data. */
      @get:Synchronized @set:Synchronized
      var maxSize: Long = maxSize
        set(value) {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 34.7K bytes
    - Viewed (0)
  4. okhttp/src/test/java/okhttp3/DuplexTest.kt

                // and resetting the stream.
                duplexResponseSent.await()
              } catch (e: InterruptedException) {
                throw AssertionError()
              }
              super.responseHeadersEnd(call, response)
            }
          }
        client =
          client.newBuilder()
            .eventListener(listener)
            .build()
        val body =
          MockStreamHandler()
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Jan 20 10:30:28 GMT 2024
    - 23.9K bytes
    - Viewed (0)
  5. okhttp/src/main/kotlin/okhttp3/internal/connection/Exchange.kt

            )
          }
          try {
            super.write(source, byteCount)
            this.bytesReceived += byteCount
          } catch (e: IOException) {
            throw complete(e)
          }
        }
    
        @Throws(IOException::class)
        override fun flush() {
          try {
            super.flush()
          } catch (e: IOException) {
            throw complete(e)
          }
        }
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 9.2K bytes
    - Viewed (2)
  6. okhttp/src/main/kotlin/okhttp3/internal/platform/AndroidPlatform.kt

        } catch (e: NoSuchMethodException) {
          super.buildTrustRootIndex(trustManager)
        }
    
      override fun getHandshakeServerNames(sslSocket: SSLSocket): List<String> {
        // The superclass implementation requires APIs not available until API 24+.
        if (Build.VERSION.SDK_INT < 24) return listOf()
        return super.getHandshakeServerNames(sslSocket)
      }
    
      /**
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 6.2K bytes
    - Viewed (0)
  7. android-test-app/src/main/kotlin/okhttp/android/testapp/MainActivity.kt

    import okhttp3.OkHttpClient
    import okhttp3.Request
    import okhttp3.Response
    import okio.IOException
    
    class MainActivity : ComponentActivity() {
      override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
    
        val client = OkHttpClient()
    
        val url = "https://github.com/square/okhttp".toHttpUrl()
        println(url.topPrivateDomain())
    
        client.newCall(Request(url)).enqueue(
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 1.5K bytes
    - Viewed (0)
  8. mockwebserver/src/main/kotlin/mockwebserver3/QueueDispatcher.kt

        if (result == DEAD_LETTER) responseQueue.add(DEAD_LETTER)
    
        return result
      }
    
      override fun peek(): MockResponse {
        return responseQueue.peek() ?: failFastResponse ?: super.peek()
      }
    
      open fun enqueueResponse(response: MockResponse) {
        responseQueue.add(response)
      }
    
      open fun clear() {
        responseQueue.clear()
      }
    
      override fun shutdown() {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Tue Jan 23 14:31:42 GMT 2024
    - 3K bytes
    - Viewed (0)
  9. okhttp/src/test/java/okhttp3/ResponseBodyTest.kt

              val source = Buffer().writeUtf8("hello")
              return object : ForwardingSource(source) {
                override fun close() {
                  closed = true
                  super.close()
                }
              }.buffer()
            }
          }
        body.source().close()
        assertThat(closed).isTrue()
      }
    
      @Test
      fun throwingUnderlyingSourceClosesQuietly() {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 4K bytes
    - Viewed (0)
Back to top