- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 10 for Next (0.18 sec)
-
samples/static-server/src/main/java/okhttp3/sample/SampleServer.java
return new MockResponse() .setStatus("HTTP/1.1 404") .addHeader("content-type: text/plain; charset=utf-8") .setBody("NOT FOUND: " + path); } catch (IOException e) { return new MockResponse() .setStatus("HTTP/1.1 500") .addHeader("content-type: text/plain; charset=utf-8") .setBody("SERVER ERROR: " + e); } }
Java - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Wed Jan 02 02:50:44 GMT 2019 - 4.7K bytes - Viewed (0) -
samples/guide/src/main/java/okhttp3/recipes/PostFile.java
import okhttp3.OkHttpClient; import okhttp3.Request; import okhttp3.RequestBody; import okhttp3.Response; public final class PostFile { public static final MediaType MEDIA_TYPE_MARKDOWN = MediaType.get("text/x-markdown; charset=utf-8"); private final OkHttpClient client = new OkHttpClient(); public void run() throws Exception { File file = new File("README.md"); Request request = new Request.Builder()
Java - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Sat May 25 18:02:55 GMT 2019 - 1.5K bytes - Viewed (0) -
samples/guide/src/main/java/okhttp3/recipes/PostStreaming.java
import okhttp3.Request; import okhttp3.RequestBody; import okhttp3.Response; import okio.BufferedSink; public final class PostStreaming { public static final MediaType MEDIA_TYPE_MARKDOWN = MediaType.get("text/x-markdown; charset=utf-8"); private final OkHttpClient client = new OkHttpClient(); public void run() throws Exception { RequestBody requestBody = new RequestBody() {
Java - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Fri Jul 06 03:18:15 GMT 2018 - 2.1K bytes - Viewed (0) -
regression-test/src/androidTest/java/okhttp/regression/IssueReproductionTest.java
* See the License for the specific language governing permissions and * limitations under the License. */ package okhttp.regression; import androidx.test.ext.junit.runners.AndroidJUnit4; import okhttp3.OkHttpClient; import okhttp3.Protocol; import okhttp3.Request; import okhttp3.Response; import org.junit.Test; import org.junit.runner.RunWith;
Java - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jul 26 06:37:08 GMT 2021 - 1.9K bytes - Viewed (0) -
samples/guide/src/main/java/okhttp3/recipes/WebSocketEcho.java
webSocket.send("...World!"); webSocket.send(ByteString.decodeHex("deadbeef")); webSocket.close(1000, "Goodbye, World!"); } @Override public void onMessage(WebSocket webSocket, String text) { System.out.println("MESSAGE: " + text); } @Override public void onMessage(WebSocket webSocket, ByteString bytes) { System.out.println("MESSAGE: " + bytes.hex()); }
Java - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Thu Apr 04 11:40:21 GMT 2024 - 1.6K bytes - Viewed (0) -
regression-test/src/androidTest/java/okhttp/regression/LetsEncryptTest.java
* See the License for the specific language governing permissions and * limitations under the License. */ package okhttp.regression; import android.os.Build; import androidx.test.ext.junit.runners.AndroidJUnit4; import java.io.ByteArrayInputStream; import java.io.IOException; import java.security.cert.Certificate; import java.security.cert.CertificateException;
Java - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Tue Nov 17 07:40:31 GMT 2020 - 6.1K bytes - Viewed (0) -
samples/slack/src/main/java/okhttp3/slack/RtmSession.java
System.out.println("onOpen: " + response); } // TOOD(jwilson): decode incoming messages and dispatch them somewhere. @Override public void onMessage(WebSocket webSocket, String text) { System.out.println("onMessage: " + text); } @Override public void onClosing(WebSocket webSocket, int code, String reason) { webSocket.close(1000, null); System.out.println("onClose (" + code + "): " + reason); }
Java - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Sat Nov 19 20:16:58 GMT 2016 - 2.4K bytes - Viewed (0) -
samples/guide/src/main/java/okhttp3/recipes/PostStreamingWithPipe.java
import okhttp3.Response; import okio.BufferedSink; import okio.Okio; import okio.Pipe; public final class PostStreamingWithPipe { public static final MediaType MEDIA_TYPE_MARKDOWN = MediaType.get("text/x-markdown; charset=utf-8"); private final OkHttpClient client = new OkHttpClient(); public void run() throws Exception { final PipeBody pipeBody = new PipeBody(); Request request = new Request.Builder()
Java - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Fri Jul 06 03:18:15 GMT 2018 - 3.1K bytes - Viewed (0) -
regression-test/src/androidTest/java/okhttp/regression/compare/OkHttpClientTest.java
* See the License for the specific language governing permissions and * limitations under the License. */ package okhttp.regression.compare; import androidx.test.ext.junit.runners.AndroidJUnit4; import java.io.IOException; import okhttp3.OkHttpClient; import okhttp3.Protocol; import okhttp3.Request; import static org.junit.Assert.assertEquals; import okhttp3.Response;
Java - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Sat Nov 14 17:38:22 GMT 2020 - 1.4K bytes - Viewed (0) -
samples/guide/src/main/java/okhttp3/recipes/PostString.java
import okhttp3.OkHttpClient; import okhttp3.Request; import okhttp3.RequestBody; import okhttp3.Response; public final class PostString { public static final MediaType MEDIA_TYPE_MARKDOWN = MediaType.get("text/x-markdown; charset=utf-8"); private final OkHttpClient client = new OkHttpClient(); public void run() throws Exception { String postBody = "" + "Releases\n" + "--------\n" + "\n"
Java - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Sat May 25 18:02:55 GMT 2019 - 1.7K bytes - Viewed (0)