Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 72 for factor (0.5 sec)

  1. okhttp-sse/src/main/kotlin/okhttp3/sse/EventSource.kt

      /**
       * Immediately and violently release resources held by this event source. This does nothing if
       * the event source has already been closed or canceled.
       */
      fun cancel()
    
      fun interface Factory {
        /**
         * Creates a new event source and immediately returns it. Creating an event source initiates an
         * asynchronous process to connect the socket. Once that succeeds or fails, `listener` will be
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 1.4K bytes
    - Viewed (0)
  2. samples/tlssurvey/src/main/kotlin/okhttp3/survey/ssllabs/SslLabsScrape.kt

    import okhttp3.survey.types.Client
    import okhttp3.survey.types.SuiteId
    import retrofit2.Retrofit
    import retrofit2.converter.moshi.MoshiConverterFactory
    
    class SslLabsScraper(
      private val callFactory: Call.Factory,
    ) {
      private val moshi = Moshi.Builder().build()
    
      private val moshiConverterFactory = MoshiConverterFactory.create(moshi)
    
      private val retrofit =
        Retrofit.Builder()
    Plain Text
    - Registered: Fri Mar 29 11:42:11 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 1.7K bytes
    - Viewed (0)
  3. okhttp/src/test/java/okhttp3/URLConnectionTest.kt

            server: MockWebServer,
            client: OkHttpClient,
          ): Call.Factory {
            return client.newBuilder()
              .proxy(Proxy.NO_PROXY)
              .build()
          }
        },
        CREATE_ARG {
          override fun connect(
            server: MockWebServer,
            client: OkHttpClient,
          ): Call.Factory {
            return client.newBuilder()
              .proxy(server.toProxyAddress())
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Jan 20 10:30:28 GMT 2024
    - 131.7K bytes
    - Viewed (0)
  4. docs/changelogs/changelog_4x.md

        receiving stream to process it.
    
        This change may increase OkHttp's memory use for applications that make many concurrent HTTP
        calls and that can receive data faster than they can process it. Previously, OkHttp limited
        HTTP/2 to 16 MiB of unacknowledged data per connection. With this fix there is a limit of 16 MiB
        of unacknowledged data per stream and no per-connection limit.
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Apr 17 13:25:31 GMT 2024
    - 25.2K bytes
    - Viewed (0)
  5. okhttp/src/test/java/okhttp3/internal/connection/RouteSelectorTest.kt

            Request.Builder()
              .url("https://$uriHost:$uriPort/")
              .build(),
          ) as RealCall
      }
    
      @AfterEach fun tearDown() {
        factory.close()
      }
    
      @Test fun singleRoute() {
        val address = factory.newAddress()
        val routeSelector = newRouteSelector(address)
        assertThat(routeSelector.hasNext()).isTrue()
        dns[uriHost] = dns.allocate(1)
        val selection = routeSelector.next()
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Mar 06 17:33:38 GMT 2024
    - 20.8K bytes
    - Viewed (0)
  6. okhttp/src/main/kotlin/okhttp3/internal/platform/BouncyCastlePlatform.kt

      override fun platformTrustManager(): X509TrustManager {
        val factory =
          TrustManagerFactory.getInstance(
            "PKIX",
            BouncyCastleJsseProvider.PROVIDER_NAME,
          )
        factory.init(null as KeyStore?)
        val trustManagers = factory.trustManagers!!
        check(trustManagers.size == 1 && trustManagers[0] is X509TrustManager) {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 3.3K bytes
    - Viewed (0)
  7. okhttp/src/main/kotlin/okhttp3/internal/platform/android/DeferredSocketAdapter.kt

     * and we can't rely on classnames after proguard, so are probably best served by falling through
     * to a situation of trying our least likely noisiest options.
     */
    class DeferredSocketAdapter(private val socketAdapterFactory: Factory) : SocketAdapter {
      private var delegate: SocketAdapter? = null
    
      override fun isSupported(): Boolean {
        return true
      }
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 2.1K bytes
    - Viewed (0)
  8. docs/recipes.md

                for (i in 2..997) {
                  sink.writeUtf8(String.format(" * $i = ${factor(i)}\n"))
                }
              }
    
              private fun factor(n: Int): String {
                for (i in 2 until n) {
                  val x = n / i
                  if (x * i == n) return "${factor(x)} × $i"
                }
                return n.toString()
              }
            }
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Fri Feb 18 08:52:22 GMT 2022
    - 40.2K bytes
    - Viewed (1)
  9. okhttp-testing-support/src/main/kotlin/okhttp3/TestValueFactory.kt

     *
     * This class is pretty fast and loose with default values: it attempts to provide values that are
     * well-formed, but doesn't guarantee values are internally consistent. Callers must take care to
     * configure the factory when sample values impact the correctness of the test.
     */
    class TestValueFactory : Closeable {
      var taskFaker: TaskFaker = TaskFaker()
      var taskRunner: TaskRunner = taskFaker.taskRunner
      var dns: Dns = Dns.SYSTEM
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Apr 20 17:03:43 GMT 2024
    - 7.7K bytes
    - Viewed (0)
  10. okhttp-android/src/main/kotlin/okhttp3/android/AndroidLogging.kt

    /**
     * An OkHttp [LoggingEventListener], with android Log as the target.
     */
    fun LoggingEventListener.Companion.androidLogging(
      priority: Int = Log.INFO,
      tag: String = "OkHttp",
    ) = LoggingEventListener.Factory { Log.println(priority, tag, it) }
    
    /**
     * An OkHttp [HttpLoggingInterceptor], with android Log as the target.
     */
    fun HttpLoggingInterceptor.Companion.androidLogging(
      priority: Int = Log.INFO,
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Apr 01 11:07:32 GMT 2024
    - 1.2K bytes
    - Viewed (0)
Back to top