Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 17 for MediaType (0.21 sec)

  1. src/mime/mediatype.go

    // attribute to the attribute value with its case preserved.
    func ParseMediaType(v string) (mediatype string, params map[string]string, err error) {
    	base, _, _ := strings.Cut(v, ";")
    	mediatype = strings.TrimSpace(strings.ToLower(base))
    
    	err = checkMediaTypeDisposition(mediatype)
    	if err != nil {
    		return "", nil, err
    	}
    
    	params = make(map[string]string)
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 9.8K bytes
    - Viewed (0)
  2. staging/src/k8s.io/apiserver/pkg/endpoints/handlers/responsewriters/writers_test.go

    	type test struct {
    		name string
    
    		mediaType  string
    		out        []byte
    		outErrs    []error
    		req        *http.Request
    		statusCode int
    		object     runtime.Object
    
    		wantCode    int
    		wantHeaders http.Header
    	}
    	newTest := func() test {
    		return test{
    			name:      "compress on gzip",
    			out:       largePayload,
    			mediaType: "application/json",
    			req: &http.Request{
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Apr 24 18:25:29 UTC 2024
    - 15.7K bytes
    - Viewed (0)
  3. okhttp/src/test/java/okhttp3/ResponseBodyJvmTest.kt

      companion object {
        @JvmOverloads
        fun body(
          hex: String,
          charset: String? = null,
        ): ResponseBody {
          val mediaType = if (charset == null) null else "any/thing; charset=$charset".toMediaType()
          return hex.decodeHex().toResponseBody(mediaType)
        }
    
        fun exhaust(reader: Reader): String {
          val builder = StringBuilder()
          val buf = CharArray(10)
          var read: Int
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Mon May 13 13:42:37 UTC 2024
    - 13K bytes
    - Viewed (0)
  4. okhttp/api/okhttp.api

    	public static final fun create (Lokhttp3/MediaType;Lokio/ByteString;)Lokhttp3/RequestBody;
    	public static final fun create (Lokhttp3/MediaType;[B)Lokhttp3/RequestBody;
    	public static final fun create (Lokhttp3/MediaType;[BI)Lokhttp3/RequestBody;
    	public static final fun create (Lokhttp3/MediaType;[BII)Lokhttp3/RequestBody;
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Mon Apr 15 13:41:01 UTC 2024
    - 70.2K bytes
    - Viewed (0)
  5. okhttp/src/main/kotlin/okhttp3/internal/-ResponseCommon.kt

    import okio.Buffer
    import okio.IOException
    import okio.Source
    import okio.Timeout
    import okio.buffer
    
    internal class UnreadableResponseBody(
      private val mediaType: MediaType?,
      private val contentLength: Long,
    ) : ResponseBody(), Source {
      override fun contentType() = mediaType
    
      override fun contentLength() = contentLength
    
      override fun source() = buffer()
    
      override fun read(
        sink: Buffer,
        byteCount: Long,
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Mon Apr 15 13:24:48 UTC 2024
    - 5.2K bytes
    - Viewed (0)
  6. fastapi/openapi/models.py

        content: Optional[Dict[str, MediaType]] = None
    
    
    class Parameter(ParameterBase):
        name: str
        in_: ParameterInType = Field(alias="in")
    
    
    class Header(ParameterBase):
        pass
    
    
    class RequestBody(BaseModelWithConfig):
        description: Optional[str] = None
        content: Dict[str, MediaType]
        required: Optional[bool] = None
    
    
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Thu Apr 18 22:49:33 UTC 2024
    - 15K bytes
    - Viewed (0)
  7. okhttp/src/test/java/okhttp3/internal/http2/HttpOverHttp2Test.kt

    import okhttp3.Cookie
    import okhttp3.Credentials.basic
    import okhttp3.EventListener
    import okhttp3.Headers.Companion.headersOf
    import okhttp3.HttpUrl.Companion.toHttpUrl
    import okhttp3.Interceptor
    import okhttp3.MediaType
    import okhttp3.MediaType.Companion.toMediaType
    import okhttp3.OkHttpClient
    import okhttp3.OkHttpClientTestRule
    import okhttp3.Protocol
    import okhttp3.RecordingCookieJar
    import okhttp3.RecordingHostnameVerifier
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Thu Apr 11 22:09:35 UTC 2024
    - 75.3K bytes
    - Viewed (0)
  8. okhttp/src/main/kotlin/okhttp3/Cache.kt

    import java.security.cert.CertificateException
    import java.security.cert.CertificateFactory
    import java.util.TreeSet
    import okhttp3.HttpUrl.Companion.toHttpUrlOrNull
    import okhttp3.MediaType.Companion.toMediaTypeOrNull
    import okhttp3.internal.EMPTY_HEADERS
    import okhttp3.internal.cache.CacheRequest
    import okhttp3.internal.cache.CacheStrategy
    import okhttp3.internal.cache.DiskLruCache
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Wed Apr 10 19:46:48 UTC 2024
    - 26.8K bytes
    - Viewed (0)
  9. cmd/auth-handler.go

    	return ok
    }
    
    // Verify if request has AWS Post policy Signature Version '4'.
    func isRequestPostPolicySignatureV4(r *http.Request) bool {
    	mediaType, _, err := mime.ParseMediaType(r.Header.Get(xhttp.ContentType))
    	if err != nil {
    		return false
    	}
    	return mediaType == "multipart/form-data" && r.Method == http.MethodPost
    }
    
    // Verify if the request has AWS Streaming Signature Version '4'. This is only valid for 'PUT' operation.
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Fri May 24 23:05:23 UTC 2024
    - 26K bytes
    - Viewed (0)
  10. okhttp/src/test/java/okhttp3/CallTest.kt

    import okhttp3.CallEvent.ResponseFailed
    import okhttp3.CertificatePinner.Companion.pin
    import okhttp3.Credentials.basic
    import okhttp3.Headers.Companion.headersOf
    import okhttp3.HttpUrl.Companion.toHttpUrl
    import okhttp3.MediaType.Companion.toMediaType
    import okhttp3.RequestBody.Companion.toRequestBody
    import okhttp3.ResponseBody.Companion.asResponseBody
    import okhttp3.TestUtil.assumeNotWindows
    import okhttp3.TestUtil.awaitGarbageCollection
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Wed Apr 10 19:46:48 UTC 2024
    - 142.5K bytes
    - Viewed (0)
Back to top