Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 303 for Content (0.17 sec)

  1. okhttp-sse/src/test/java/okhttp3/sse/internal/EventSourceHttpTest.kt

            .body(
              """
              |data: hey
              |
              |
              """.trimMargin(),
            ).setHeader("content-type", "text/plain")
            .build(),
        )
        newEventSource()
        listener.assertFailure("Invalid content-type: text/plain")
      }
    
      @Test
      fun badResponseCode() {
        server.enqueue(
          MockResponse.Builder()
            .body(
              """
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sun Jan 14 10:20:09 GMT 2024
    - 6.6K bytes
    - Viewed (0)
  2. okhttp/src/test/java/okhttp3/CacheTest.kt

        assertThat(cache.hitCount()).isEqualTo(0)
      }
    
      private fun corruptCertificate(cacheEntry: Path) {
        var content = fileSystem.source(cacheEntry).buffer().readUtf8()
        content = content.replace("MII", "!!!")
        fileSystem.sink(cacheEntry).buffer().writeUtf8(content).close()
      }
    
      @Test
      fun responseCachingAndRedirects() {
        server.enqueue(
          MockResponse.Builder()
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Apr 10 19:46:48 GMT 2024
    - 108.6K bytes
    - Viewed (0)
  3. build-logic-commons/gradle-plugin/src/main/kotlin/gradlebuild.repositories.gradle.kts

     * limitations under the License.
     */
    
    repositories {
        maven {
            name = "Gradle public repository"
            url = uri("https://repo.gradle.org/gradle/public")
            content {
                includeGroup("net.rubygrapefruit")
                includeModule("flot", "flot")
                includeModule("org.gradle", "gradle-tooling-api")
    Plain Text
    - Registered: Wed May 01 11:36:15 GMT 2024
    - Last Modified: Fri Apr 05 14:05:00 GMT 2024
    - 1.4K bytes
    - Viewed (0)
  4. samples/guide/src/main/java/okhttp3/recipes/kt/ParseResponseWithMoshi.kt

          for ((key, value) in gist!!.files!!) {
            println(key)
            println(value.content)
          }
        }
      }
    
      @JsonClass(generateAdapter = true)
      data class Gist(var files: Map<String, GistFile>?)
    
      @JsonClass(generateAdapter = true)
      data class GistFile(var content: String?)
    }
    
    fun main() {
      ParseResponseWithMoshi().run()
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 1.6K bytes
    - Viewed (1)
  5. okhttp/src/main/kotlin/okhttp3/internal/-ResponseBodyCommon.kt

      val contentLength = contentLength()
      if (contentLength > Int.MAX_VALUE) {
        throw IOException("Cannot buffer entire body for content length: $contentLength")
      }
    
      val bytes = source().use(consumer)
      val size = sizeMapper(bytes)
      if (contentLength != -1L && contentLength != size.toLong()) {
        throw IOException("Content-Length ($contentLength) and stream length ($size) disagree")
      }
      return bytes
    }
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 2.3K bytes
    - Viewed (0)
  6. docs/zh/docs/advanced/additional-responses.md

                "description": "Additional Response",
                "content": {
                    "application/json": {
                        "schema": {
                            "$ref": "#/components/schemas/Message"
                        }
                    }
                }
            },
            "200": {
                "description": "Successful Response",
                "content": {
                    "application/json": {
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Jan 09 15:53:39 GMT 2024
    - 8.2K bytes
    - Viewed (0)
  7. okhttp/src/test/java/okhttp3/RequestBodyTest.kt

          FileInputStream(filePath.toFile()).use { fis ->
            fn(fis.fd)
          }
        }
      }
    
      private inline fun <T> assertOnPath(
        content: String? = null,
        fn: (okio.Path) -> T,
      ): T {
        FileSystem.SYSTEM.write(filePath) {
          if (content != null) {
            writeUtf8(content)
          }
        }
    
        return fn(filePath)
      }
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 3.6K bytes
    - Viewed (1)
  8. docs/en/docs/reference/uploadfile.md

    ```python
    from fastapi import UploadFile
    ```
    
    ::: fastapi.UploadFile
        options:
            members:
                - file
                - filename
                - size
                - headers
                - content_type
                - read
                - write
                - seek
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:53:19 GMT 2024
    - 472 bytes
    - Viewed (0)
  9. okhttp-logging-interceptor/src/main/kotlin/okhttp3/logging/HttpLoggingInterceptor.kt

           *
           * Example:
           * ```
           * --> POST /greeting http/1.1
           * Host: example.com
           * Content-Type: plain/text
           * Content-Length: 3
           * --> END POST
           *
           * <-- 200 OK (22ms)
           * Content-Type: plain/text
           * Content-Length: 6
           * <-- END HTTP
           * ```
           */
          HEADERS,
    
          /**
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Apr 06 09:14:38 GMT 2024
    - 11.2K bytes
    - Viewed (1)
  10. okhttp/src/main/kotlin/okhttp3/internal/cache/CacheStrategy.kt

        ): Boolean {
          // Always go to network for uncacheable response codes (RFC 7231 section 6.1), This
          // implementation doesn't support caching partial content.
          when (response.code) {
            HTTP_OK,
            HTTP_NOT_AUTHORITATIVE,
            HTTP_NO_CONTENT,
            HTTP_MULT_CHOICE,
            HTTP_MOVED_PERM,
            HTTP_NOT_FOUND,
            HTTP_BAD_METHOD,
            HTTP_GONE,
            HTTP_REQ_TOO_LONG,
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Apr 15 13:24:48 GMT 2024
    - 12K bytes
    - Viewed (0)
Back to top