Search Options

Results per page
Sort
Preferred Languages
Advance

Results 441 - 450 of 531 for Fun (0.05 sec)

  1. okhttp/src/main/kotlin/okhttp3/internal/connection/ExchangeFinder.kt

     * See the License for the specific language governing permissions and
     * limitations under the License.
     */
    package okhttp3.internal.connection
    
    interface ExchangeFinder {
      val routePlanner: RoutePlanner
    
      fun find(): RealConnection
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Wed Dec 20 23:27:07 UTC 2023
    - 730 bytes
    - Viewed (0)
  2. okhttp/src/test/java/okhttp3/WebPlatformToAsciiData.kt

     */
    @Serializable
    class WebPlatformToAsciiData {
      var input: String? = null
      var output: String? = null
      var comment: String? = null
    
      override fun toString() = "input=$input output=$output"
    
      companion object {
        fun load(): List<WebPlatformToAsciiData> {
          val path = okHttpRoot / "okhttp/src/test/resources/web-platform-test-toascii.json"
          return SYSTEM_FILE_SYSTEM.read(path) {
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Wed Dec 20 23:27:07 UTC 2023
    - 1.4K bytes
    - Viewed (0)
  3. okhttp/src/main/kotlin/okhttp3/internal/http1/HeadersReader.kt

      private var headerLimit = HEADER_LIMIT.toLong()
    
      /** Read a single line counted against the header size limit. */
      fun readLine(): String {
        val line = source.readUtf8LineStrict(headerLimit)
        headerLimit -= line.length.toLong()
        return line
      }
    
      /** Reads headers or trailers. */
      fun readHeaders(): Headers {
        val result = Headers.Builder()
        while (true) {
          val line = readLine()
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Wed Dec 20 23:27:07 UTC 2023
    - 1.4K bytes
    - Viewed (0)
  4. okhttp/src/test/java/okhttp3/internal/http/ExternalHttp2Example.kt

     * limitations under the License.
     */
    package okhttp3.internal.http
    
    import okhttp3.OkHttpClient
    import okhttp3.Protocol
    import okhttp3.Request
    
    object ExternalHttp2Example {
      @JvmStatic
      fun main(args: Array<String>) {
        val client =
          OkHttpClient.Builder()
            .protocols(listOf(Protocol.HTTP_2, Protocol.HTTP_1_1))
            .build()
        val call =
          client.newCall(
            Request.Builder()
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 1.4K bytes
    - Viewed (0)
  5. mockwebserver/src/main/kotlin/mockwebserver3/internal/TriggerSink.kt

     */
    internal class TriggerSink(
      private val delegate: Sink,
      private val triggerByteCount: Long,
      private val trigger: () -> Unit,
    ) : Sink by delegate {
      private var bytesWritten = 0L
    
      override fun write(
        source: Buffer,
        byteCount: Long,
      ) {
        if (byteCount == 0L) return // Avoid double-triggering.
    
        if (bytesWritten == triggerByteCount) {
          source.skip(byteCount)
          return
        }
    
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 1.4K bytes
    - Viewed (0)
  6. okhttp-brotli/src/main/kotlin/okhttp3/brotli/BrotliInterceptor.kt

     * responses.  n.b. this replaces the transparent gzip compression in BridgeInterceptor.
     */
    object BrotliInterceptor : Interceptor {
      override fun intercept(chain: Interceptor.Chain): Response {
        return if (chain.request().header("Accept-Encoding") == null) {
          val request =
            chain.request().newBuilder()
              .header("Accept-Encoding", "br,gzip")
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 1.3K bytes
    - Viewed (0)
  7. okhttp-logging-interceptor/src/main/kotlin/okhttp3/logging/internal/IsProbablyUtf8.kt

    import okio.Buffer
    
    /**
     * Returns true if the body in question probably contains human readable text. Uses a small
     * sample of code points to detect unicode control characters commonly used in binary file
     * signatures.
     */
    fun Buffer.isProbablyUtf8(): Boolean {
      try {
        val prefix = Buffer()
        val byteCount = size.coerceAtMost(64)
        copyTo(prefix, 0, byteCount)
        for (i in 0 until 16) {
          if (prefix.exhausted()) {
            break
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sun Jan 07 16:05:34 UTC 2024
    - 1.4K bytes
    - Viewed (0)
  8. okhttp/src/test/java/okhttp3/OkHttpTest.kt

     * limitations under the License.
     */
    package okhttp3
    
    import assertk.assertThat
    import assertk.assertions.matches
    import org.junit.jupiter.api.Test
    
    class OkHttpTest {
      @Test
      fun testVersion() {
        assertThat(OkHttp.VERSION).matches(Regex("[0-9]+\\.[0-9]+\\.[0-9]+(-.+)?"))
      }
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Thu Dec 21 01:54:49 UTC 2023
    - 848 bytes
    - Viewed (0)
  9. samples/tlssurvey/src/main/kotlin/okhttp3/survey/ssllabs/SslLabsClient.kt

      suspend fun clients(): List<Client> {
        return sslLabsApi.clients().map { userAgent ->
          Client(
            userAgent = userAgent.name,
            version = userAgent.version,
            platform = userAgent.platform,
            enabled = userAgent.suiteNames.map { SuiteId(null, it) },
          )
        }
      }
    }
    
    suspend fun main() {
      val sslLabsClient =
        SslLabsClient(
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Tue Apr 02 01:44:15 UTC 2024
    - 1.7K bytes
    - Viewed (0)
  10. okhttp-hpacktests/src/test/java/okhttp3/internal/http2/hpackjson/Case.kt

          for (inputHeader in headers) {
            val (key, value) = inputHeader.entries.iterator().next()
            result.add(Header(key, value))
          }
          return result
        }
    
      public override fun clone() = Case(seqno, this.wire, headers)
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sat Dec 23 10:26:25 UTC 2023
    - 1.3K bytes
    - Viewed (0)
Back to top