Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 32 for EventListener (0.14 sec)

  1. okhttp-testing-support/src/main/kotlin/okhttp3/OkHttpClientTestRule.kt

        Logger.getLogger(TaskRunner::class.java.name).fn()
        Logger.getLogger("javax.net.ssl").fn()
      }
    
      fun wrap(eventListener: EventListener) = EventListener.Factory { ClientRuleEventListener(eventListener, ::addEvent) }
    
      fun wrap(eventListenerFactory: EventListener.Factory) =
        EventListener.Factory { call -> ClientRuleEventListener(eventListenerFactory.create(call), ::addEvent) }
    
      /**
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 10.5K bytes
    - Viewed (0)
  2. samples/guide/src/main/java/okhttp3/recipes/kt/WiresharkExample.kt

     */
    @SuppressSignatureCheck
    class WireSharkListenerFactory(
      private val logFile: File,
      private val tlsVersions: List<TlsVersion>,
      private val launch: Launch? = null,
    ) : EventListener.Factory {
      override fun create(call: Call): EventListener {
        return WireSharkKeyLoggerListener(logFile, launch == null)
      }
    
      fun launchWireShark(): Process? {
        when (launch) {
          null -> {
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 10.7K bytes
    - Viewed (0)
  3. okhttp/src/test/java/okhttp3/KotlinSourceModernTest.kt

              ioe: IOException,
            ) = TODO()
    
            override fun canceled(call: Call) = TODO()
          }
        val none: EventListener = EventListener.NONE
      }
    
      @Test
      fun eventListenerBuilder() {
        var builder: EventListener.Factory = EventListener.Factory { TODO() }
      }
    
      @Test
      fun formBody() {
        val formBody: FormBody = FormBody.Builder().build()
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Mon Apr 01 14:21:25 UTC 2024
    - 46.5K bytes
    - Viewed (0)
  4. okhttp-logging-interceptor/api/logging-interceptor.api

    }
    
    public class okhttp3/logging/LoggingEventListener$Factory : okhttp3/EventListener$Factory {
    	public fun <init> ()V
    	public fun <init> (Lokhttp3/logging/HttpLoggingInterceptor$Logger;)V
    	public synthetic fun <init> (Lokhttp3/logging/HttpLoggingInterceptor$Logger;ILkotlin/jvm/internal/DefaultConstructorMarker;)V
    	public fun create (Lokhttp3/Call;)Lokhttp3/EventListener;
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Sat Apr 06 09:14:38 UTC 2024
    - 4.5K bytes
    - Viewed (0)
  5. okhttp/src/main/kotlin/okhttp3/internal/cache/CacheInterceptor.kt

        val networkRequest = strategy.networkRequest
        val cacheResponse = strategy.cacheResponse
    
        cache?.trackResponse(strategy)
        val listener = (call as? RealCall)?.eventListener ?: EventListener.NONE
    
        if (cacheCandidate != null && cacheResponse == null) {
          // The cache candidate wasn't applicable. Close it.
          cacheCandidate.body.closeQuietly()
        }
    
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Fri Mar 22 07:09:21 UTC 2024
    - 10.2K bytes
    - Viewed (0)
  6. okhttp/src/test/java/okhttp3/ConnectionCoalescingTest.kt

        val latch1 = CountDownLatch(1)
        val latch2 = CountDownLatch(1)
        val latch3 = CountDownLatch(1)
        val latch4 = CountDownLatch(1)
        val listener1: EventListener =
          object : EventListener() {
            override fun connectStart(
              call: Call,
              inetSocketAddress: InetSocketAddress,
              proxy: Proxy,
            ) {
              try {
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Sat Jan 20 10:30:28 UTC 2024
    - 18.7K bytes
    - Viewed (0)
  7. okhttp/src/main/kotlin/okhttp3/internal/-UtilJvm.kt

    internal fun HttpUrl.canReuseConnectionFor(other: HttpUrl): Boolean =
      host == other.host &&
        port == other.port &&
        scheme == other.scheme
    
    internal fun EventListener.asFactory() = EventListener.Factory { this }
    
    /**
     * Reads until this is exhausted or the deadline has been reached. This is careful to not extend the
     * deadline if one exists already.
     */
    @Throws(IOException::class)
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Mon May 13 13:42:37 UTC 2024
    - 10.7K bytes
    - Viewed (0)
  8. okhttp/src/main/kotlin/okhttp3/OkHttpClient.kt

         * client.
         *
         * @see EventListener for semantics and restrictions on listener implementations.
         */
        fun eventListener(eventListener: EventListener) =
          apply {
            this.eventListenerFactory = eventListener.asFactory()
          }
    
        /**
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Sat Apr 06 04:21:33 UTC 2024
    - 52K bytes
    - Viewed (0)
  9. okhttp/src/main/kotlin/okhttp3/internal/ws/RealWebSocket.kt

          failWebSocket(ProtocolException("Request header not permitted: 'Sec-WebSocket-Extensions'"))
          return
        }
    
        val webSocketClient =
          client.newBuilder()
            .eventListener(EventListener.NONE)
            .protocols(ONLY_HTTP1)
            .build()
        val request =
          originalRequest.newBuilder()
            .header("Upgrade", "websocket")
            .header("Connection", "Upgrade")
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Mon Apr 01 14:21:25 UTC 2024
    - 22.1K bytes
    - Viewed (0)
  10. okhttp/src/test/java/okhttp3/JSSETest.kt

        val sessionIds = mutableListOf<String>()
    
        assumeNetwork()
    
        client =
          client.newBuilder()
            .eventListenerFactory(
              clientTestRule.wrap(
                object : EventListener() {
                  override fun connectionAcquired(
                    call: Call,
                    connection: Connection,
                  ) {
                    val sslSocket = connection.socket() as SSLSocket
    
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Sat Jan 20 10:30:28 UTC 2024
    - 5.4K bytes
    - Viewed (0)
Back to top