Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 118 for media (0.13 sec)

  1. android/guava/src/com/google/common/net/MediaType.java

     * (also known as a MIME Type or Content Type). This class also supports the concept of media ranges
     * <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.1">defined by HTTP/1.1</a>.
     * As such, the {@code *} character is treated as a wildcard and is used to represent any acceptable
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Aug 07 16:17:10 GMT 2023
    - 46.2K bytes
    - Viewed (0)
  2. docs/en/docs/advanced/custom-response.md

    * `content` - A `str` or `bytes`.
    * `status_code` - An `int` HTTP status code.
    * `headers` - A `dict` of strings.
    * `media_type` - A `str` giving the media type. E.g. `"text/html"`.
    
    FastAPI (actually Starlette) will automatically include a Content-Length header. It will also include a Content-Type header, based on the media_type and appending a charset for text types.
    
    ```Python hl_lines="1  18"
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Thu Apr 18 19:53:19 GMT 2024
    - 11.7K bytes
    - Viewed (0)
  3. fastapi/openapi/utils.py

        )
        field_info = cast(Body, body_field.field_info)
        request_media_type = field_info.media_type
        required = body_field.required
        request_body_oai: Dict[str, Any] = {}
        if required:
            request_body_oai["required"] = required
        request_media_content: Dict[str, Any] = {"schema": body_schema}
        if field_info.openapi_examples:
            request_media_content["examples"] = jsonable_encoder(
    Python
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 21.8K bytes
    - Viewed (0)
  4. fastapi/params.py

            include_in_schema: bool = True,
            json_schema_extra: Union[Dict[str, Any], None] = None,
            **extra: Any,
        ):
            self.embed = embed
            self.media_type = media_type
            if example is not _Unset:
                warnings.warn(
                    "`example` has been deprecated, please use `examples` instead",
                    category=DeprecationWarning,
    Python
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 27.5K bytes
    - Viewed (1)
  5. docs/recipes.md

                .post(postBody.toRequestBody(MEDIA_TYPE_MARKDOWN))
                .build()
    
            client.newCall(request).execute().use { response ->
              if (!response.isSuccessful) throw IOException("Unexpected code $response")
    
              println(response.body!!.string())
            }
          }
    
          companion object {
            val MEDIA_TYPE_MARKDOWN = "text/x-markdown; charset=utf-8".toMediaType()
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Fri Feb 18 08:52:22 GMT 2022
    - 40.2K bytes
    - Viewed (1)
  6. fastapi/dependencies/utils.py

        else:
            BodyFieldInfo = params.Body
    
            body_param_media_types = [
                f.field_info.media_type
                for f in flat_dependant.body_params
                if isinstance(f.field_info, params.Body)
            ]
            if len(set(body_param_media_types)) == 1:
                BodyFieldInfo_kwargs["media_type"] = body_param_media_types[0]
        final_field = create_response_field(
            name="body",
    Python
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Tue Apr 02 02:52:56 GMT 2024
    - 29.5K bytes
    - Viewed (0)
  7. docs/de/docs/advanced/custom-response.md

    * `status_code` – Ein `int`-HTTP-Statuscode.
    * `headers` – Ein `dict` von Strings.
    * `media_type` – Ein `str`, der den Medientyp angibt. Z. B. `"text/html"`.
    
    FastAPI (eigentlich Starlette) fügt automatisch einen Content-Length-Header ein. Außerdem wird es einen Content-Type-Header einfügen, der auf dem media_type basiert, und für Texttypen einen Zeichensatz (charset) anfügen.
    
    ```Python hl_lines="1  18"
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Tue Jan 23 13:05:12 GMT 2024
    - 13.5K bytes
    - Viewed (0)
  8. docs/de/docs/tutorial/schema-extra-example.md

        * `Path()`
        * `Query()`
        * `Header()`
        * `Cookie()`
    * <a href="https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.1.0.md#media-type-object" class="external-link" target="_blank">`Request Body Object` im Feld `content` des `Media Type Object`s (in der Spezifikation)</a>, das verwendet wurde von FastAPIs:
        * `Body()`
        * `File()`
        * `Form()`
    
    !!! info
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Sat Mar 30 20:19:53 GMT 2024
    - 13.3K bytes
    - Viewed (0)
  9. docs/en/docs/tutorial/schema-extra-example.md

        * `Path()`
        * `Query()`
        * `Header()`
        * `Cookie()`
    * <a href="https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.1.0.md#media-type-object" class="external-link" target="_blank">`Request Body Object`, in the field `content`, on the `Media Type Object` (in the specification)</a> that was used by FastAPI's:
        * `Body()`
        * `File()`
        * `Form()`
    
    !!! info
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Thu Apr 18 19:53:19 GMT 2024
    - 11.8K bytes
    - Viewed (0)
  10. docs/ja/docs/advanced/custom-response.md

    直接返すことができます。
    
    以下のパラメータを受け付けます。
    
    * `content` - `str` か `bytes`。
    * `status_code` - `int` のHTTPステータスコード。
    * `headers` - 文字列の `dict` 。
    * `media_type` - メディアタイプを示す `str` 。例えば `"text/html"` 。
    
    FastAPI (実際にはStarlette) は自動的にContent-Lengthヘッダーを含みます。また、media_typeに基づいたContent-Typeヘッダーを含み、テキストタイプのためにcharsetを追加します。
    
    ```Python hl_lines="1  18"
    {!../../../docs_src/response_directly/tutorial002.py!}
    ```
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Mon Jul 19 19:14:58 GMT 2021
    - 10.7K bytes
    - Viewed (0)
Back to top