- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 13 for Header1 (0.2 sec)
-
docs/recipes.md
When writing request headers, use `header(name, value)` to set the only occurrence of `name` to `value`. If there are existing values, they will be removed before the new value is added. Use `addHeader(name, value)` to add a header without removing the headers already present.
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Sat Aug 30 17:01:12 UTC 2025 - 47.8K bytes - Viewed (0) -
okhttp-sse/src/test/java/okhttp3/sse/internal/EventSourceHttpTest.kt
response.request .newBuilder() .header("Authorization", "XYZ") .build() }.build() server.enqueue( MockResponse( code = 401, body = "{\"error\":{\"message\":\"No auth credentials found\",\"code\":401}}", headers = Headers.headersOf("content-type", "application/json"), ), ) server.enqueue(
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Sat Aug 30 11:47:47 UTC 2025 - 8.1K bytes - Viewed (0) -
okhttp-sse/src/test/java/okhttp3/sse/internal/EventSourcesHttpTest.kt
headers = Headers.headersOf("content-type", "application/json"), ), ) server.enqueue( MockResponse( body = """ |data: hey | | """.trimMargin(), headers = Headers.headersOf("content-type", "text/event-stream"), ), )
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Sat Aug 30 13:49:38 UTC 2025 - 3.6K bytes - Viewed (0) -
pom.xml
<year>2025</year> </properties> <headerDefinitions> <headerDefinition>https://www.codelibs.org/assets/license/header-definition-2.xml</headerDefinition> </headerDefinitions> <licenseSets> <licenseSet> <header>https://www.codelibs.org/assets/license/header.txt</header> <includes> <include>src/**/*.java</include> </includes> </licenseSet> </licenseSets>
Registered: Fri Sep 05 20:58:11 UTC 2025 - Last Modified: Sun Aug 31 03:01:32 UTC 2025 - 4.9K bytes - Viewed (0) -
samples/guide/src/main/java/okhttp3/recipes/kt/UploadProgress.kt
} } val file = File("docs/images/logo-square.png") val requestBody: RequestBody = file.asRequestBody(MEDIA_TYPE_PNG) val request = Request .Builder() .header("Authorization", "Client-ID $IMGUR_CLIENT_ID") .url("https://api.imgur.com/3/image") .post(ProgressRequestBody(requestBody, progressListener)) .build()
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Sat Aug 30 17:01:12 UTC 2025 - 3.8K bytes - Viewed (0) -
okhttp-sse/src/test/java/okhttp3/sse/internal/EventSourceFactoryTest.java
@Override public void onOpen(@NotNull EventSource eventSource, @NotNull Response response) { try { assertEquals("text/event-stream", response.request().header("Accept")); } catch (Exception e) { future.completeExceptionally(e); } } @Override
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Sat Aug 30 11:47:47 UTC 2025 - 2.8K bytes - Viewed (0) -
okhttp-sse/src/main/kotlin/okhttp3/sse/EventSource.kt
*/ @JvmStatic @JvmName("create") fun Call.Factory.asEventSourceFactory(): Factory = Factory { request, listener -> val actualRequest = if (request.header("Accept") == null) { request.newBuilder().addHeader("Accept", "text/event-stream").build() } else { request }
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Sat Aug 30 11:47:47 UTC 2025 - 2.5K bytes - Viewed (0) -
okhttp-sse/src/main/kotlin/okhttp3/sse/internal/RealEventSource.kt
// Replace the body with a stripped one so the callbacks can't see real data. val response = response.stripBody() val reader = ServerSentEventReader(body.source(), this) try { if (!canceled) { listener.onOpen(this, response) while (!canceled && reader.processNextEvent()) { } } } catch (e: Exception) { val exception = when {
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Sat Aug 30 11:47:47 UTC 2025 - 3.3K bytes - Viewed (0) -
README.md
mvn test -Dtest=BeanUtilTest#testCopyBeanToBean ``` ### Code Quality and Formatting ```bash # Format code according to project standards mvn formatter:format # Apply license headers to source files mvn license:format # Build JAR with all verifications mvn clean package # Generate test coverage report mvn verify # Coverage report available at: target/site/jacoco/index.html ```
Registered: Fri Sep 05 20:58:11 UTC 2025 - Last Modified: Sun Aug 31 02:56:02 UTC 2025 - 12.7K bytes - Viewed (0) -
samples/guide/src/main/java/okhttp3/recipes/UploadProgress.java
} } }; RequestBody requestBody = RequestBody.create( new File("docs/images/logo-square.png"), MEDIA_TYPE_PNG); Request request = new Request.Builder() .header("Authorization", "Client-ID " + IMGUR_CLIENT_ID) .url("https://api.imgur.com/3/image") .post(new ProgressRequestBody(requestBody, progressListener)) .build();
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Sat Aug 30 17:01:12 UTC 2025 - 4.2K bytes - Viewed (1)