Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for enqueueTrailers (0.07 sec)

  1. okhttp/src/main/kotlin/okhttp3/internal/http2/Http2Stream.kt

          }
        }
    
        connection.writeHeaders(id, outFinished, responseHeaders)
    
        if (flushHeaders) {
          connection.flush()
        }
      }
    
      fun enqueueTrailers(trailers: Headers) {
        this.withLock {
          check(!sink.finished) { "already finished" }
          require(trailers.size != 0) { "trailers.size() == 0" }
          this.sink.trailers = trailers
        }
      }
    
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sat Apr 20 17:03:43 UTC 2024
    - 23.2K bytes
    - Viewed (0)
  2. okhttp/src/test/java/okhttp3/internal/http2/Http2ConnectionTest.kt

        peer.acceptFrame() // HEADERS STREAM 3
        peer.play()
    
        // Play it back.
        val connection = connect(peer)
        val stream = connection.newStream(headerEntries("a", "android"), true)
        stream.enqueueTrailers(headersOf("foo", "bar"))
        val sink = stream.getSink().buffer()
        sink.writeUtf8("abcdefghi")
        sink.close()
    
        // Verify the peer received what was expected.
        val headers1 = peer.takeFrame()
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sat Apr 20 17:03:43 UTC 2024
    - 75.4K bytes
    - Viewed (0)
  3. mockwebserver/src/main/kotlin/mockwebserver3/MockWebServer.kt

          }
    
          sleepNanos(response.headersDelayNanos)
          stream.writeHeaders(response.toHttp2Headers(), outFinished, flushHeaders)
    
          if (trailers.size > 0) {
            stream.enqueueTrailers(trailers)
          }
          pushPromises(stream, request, response.pushPromises)
          if (body != null) {
            sleepNanos(bodyDelayNanos)
            val responseBodySink =
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sun Mar 31 17:16:15 UTC 2024
    - 37.4K bytes
    - Viewed (0)
Back to top