- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 30 for Nelson (0.19 sec)
-
container-tests/src/test/java/okhttp3/containers/SocksProxyTest.kt
MockServerClient(mockServer.host, mockServer.serverPort).use { mockServerClient -> mockServerClient .`when`( request().withPath("/person") .withQueryStringParameter("name", "peter"), ) .respond(response().withBody("Peter the person!")) val client = OkHttpClient.Builder() .proxy(Proxy(SOCKS, InetSocketAddress(socks5Proxy.host, socks5Proxy.firstMappedPort)))
Plain Text - Registered: Fri Apr 26 11:42:10 GMT 2024 - Last Modified: Fri Apr 05 03:30:42 GMT 2024 - 2.6K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/ws/RealWebSocket.kt
override fun close( code: Int, reason: String?, ): Boolean { return close(code, reason, webSocketCloseTimeout) } @Synchronized fun close( code: Int, reason: String?, cancelAfterCloseMillis: Long, ): Boolean { validateCloseCode(code) var reasonBytes: ByteString? = null if (reason != null) { reasonBytes = reason.encodeUtf8()
Plain Text - Registered: Fri Apr 26 11:42:10 GMT 2024 - Last Modified: Mon Apr 01 14:21:25 GMT 2024 - 22.1K bytes - Viewed (0) -
samples/guide/src/main/java/okhttp3/recipes/WebSocketEcho.java
System.out.println("MESSAGE: " + bytes.hex()); } @Override public void onClosing(WebSocket webSocket, int code, String reason) { webSocket.close(1000, null); System.out.println("CLOSE: " + code + " " + reason); } @Override public void onFailure(WebSocket webSocket, Throwable t, Response response) { t.printStackTrace(); }
Java - Registered: Fri Apr 26 11:42:10 GMT 2024 - Last Modified: Thu Apr 04 11:40:21 GMT 2024 - 1.6K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/WebSocketListener.kt
webSocket: WebSocket, code: Int, reason: String, ) { } /** * Invoked when both peers have indicated that no more messages will be transmitted and the * connection has been successfully released. No further calls to this listener will be made. */ open fun onClosed( webSocket: WebSocket, code: Int, reason: String, ) { } /**
Plain Text - Registered: Fri Apr 26 11:42:10 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 2K bytes - Viewed (0) -
mockwebserver-deprecated/src/main/kotlin/okhttp3/mockwebserver/MockResponse.kt
fun setResponseCode(code: Int): MockResponse { val reason = when (code) { in 100..199 -> "Informational" in 200..299 -> "OK" in 300..399 -> "Redirection" in 400..499 -> "Client Error" in 500..599 -> "Server Error" else -> "Mock Response" } return apply { status = "HTTP/1.1 $code $reason" } } fun clearHeaders() = apply {
Plain Text - Registered: Fri Apr 26 11:42:10 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 7.2K bytes - Viewed (0) -
okhttp-logging-interceptor/src/test/java/okhttp3/logging/LoggingEventListenerTest.kt
.assertLogMatch(Regex("""callEnd""")) .assertNoMoreLogs() } @Test fun dnsFail() { client = OkHttpClient.Builder() .dns { _ -> throw UnknownHostException("reason") } .eventListenerFactory(loggingEventListenerFactory) .build() try { client.newCall(request().build()).execute() fail<Any>() } catch (expected: UnknownHostException) { }
Plain Text - Registered: Fri Apr 26 11:42:10 GMT 2024 - Last Modified: Sun Jan 14 10:20:09 GMT 2024 - 10.2K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/http2/PushObserver.kt
*/ @Throws(IOException::class) fun onData( streamId: Int, source: BufferedSource, byteCount: Int, last: Boolean, ): Boolean /** Indicates the reason why this stream was canceled. */ fun onReset( streamId: Int, errorCode: ErrorCode, ) companion object { @JvmField val CANCEL: PushObserver = PushObserverCancel()
Plain Text - Registered: Fri Apr 26 11:42:10 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 3.6K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/KotlinSourceModernTest.kt
Plain Text - Registered: Fri Apr 26 11:42:10 GMT 2024 - Last Modified: Mon Apr 01 14:21:25 GMT 2024 - 46.5K bytes - Viewed (4) -
container-tests/src/test/java/okhttp3/containers/BasicMockServerTest.kt
.`when`( request().withPath("/person") .withQueryStringParameter("name", "peter"), ) .respond(response().withBody("Peter the person!")) val response = client.newCall(Request((mockServer.endpoint + "/person?name=peter").toHttpUrl())).execute() assertThat(response.body.string()).contains("Peter the person") } } @Test fun testHttpsRequest() {
Plain Text - Registered: Fri Apr 26 11:42:10 GMT 2024 - Last Modified: Fri Apr 05 03:30:42 GMT 2024 - 3.3K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/ws/WebSocketHttpTest.kt
val server = serverListener.assertOpen() clientListener.assertOpen() val reason = repeat('X', 124) assertFailsWith<IllegalArgumentException> { webSocket.close(1000, reason) }.also { expected -> assertThat(expected.message).isEqualTo("reason.size() > 123: $reason") } webSocket.close(1000, null) serverListener.assertClosing(1000, "") server.close(1000, null)
Plain Text - Registered: Fri Apr 26 11:42:10 GMT 2024 - Last Modified: Sun Mar 31 17:16:15 GMT 2024 - 35.2K bytes - Viewed (1)