Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 7 of 7 for 18 (0.94 sec)

  1. docs/ru/docs/tutorial/extra-models.md

    Таким же образом вы можете определять ответы как списки объектов.
    
    Для этого используйте `typing.List` из стандартной библиотеки Python (или просто `list` в Python 3.9 и выше):
    
    === "Python 3.9+"
    
        ```Python hl_lines="18"
        {!> ../../../docs_src/extra_models/tutorial004_py39.py!}
        ```
    
    === "Python 3.8+"
    
        ```Python hl_lines="1  20"
        {!> ../../../docs_src/extra_models/tutorial004.py!}
        ```
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Fri Mar 22 01:42:11 GMT 2024
    - 11.6K bytes
    - Viewed (0)
  2. docs/en/docs/tutorial/extra-models.md

    The same way, you can declare responses of lists of objects.
    
    For that, use the standard Python `typing.List` (or just `list` in Python 3.9 and above):
    
    === "Python 3.9+"
    
        ```Python hl_lines="18"
        {!> ../../../docs_src/extra_models/tutorial004_py39.py!}
        ```
    
    === "Python 3.8+"
    
        ```Python hl_lines="1  20"
        {!> ../../../docs_src/extra_models/tutorial004.py!}
        ```
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Thu Apr 18 19:53:19 GMT 2024
    - 7.7K bytes
    - Viewed (1)
  3. docs/pt/docs/tutorial/extra-models.md

    === "Python 3.8 and above"
    
        ```Python hl_lines="1  20"
        {!> ../../../docs_src/extra_models/tutorial004.py!}
        ```
    
    === "Python 3.9 and above"
    
        ```Python hl_lines="18"
        {!> ../../../docs_src/extra_models/tutorial004_py39.py!}
        ```
    
    ## Resposta com `dict` arbitrário
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Fri Mar 22 01:42:11 GMT 2024
    - 7.8K bytes
    - Viewed (0)
  4. docs/em/docs/tutorial/extra-models.md

    === "🐍 3️⃣.6️⃣ & 🔛"
    
        ```Python hl_lines="1  20"
        {!> ../../../docs_src/extra_models/tutorial004.py!}
        ```
    
    === "🐍 3️⃣.9️⃣ & 🔛"
    
        ```Python hl_lines="18"
        {!> ../../../docs_src/extra_models/tutorial004_py39.py!}
        ```
    
    ## 📨 ⏮️ ❌ `dict`
    
    👆 💪 📣 📨 ⚙️ ✅ ❌ `dict`, 📣 🆎 🔑 & 💲, 🍵 ⚙️ Pydantic 🏷.
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Thu Apr 18 19:53:19 GMT 2024
    - 6.8K bytes
    - Viewed (0)
  5. docs/zh/docs/tutorial/extra-models.md

        {!> ../../../docs_src/extra_models/tutorial003.py!}
        ```
    
    ## 模型列表
    
    使用同样的方式也可以声明由对象列表构成的响应。
    
    为此,请使用标准的 Python `typing.List`:
    
    === "Python 3.9+"
    
        ```Python hl_lines="18"
        {!> ../../../docs_src/extra_models/tutorial004_py39.py!}
        ```
    
    === "Python 3.8+"
    
        ```Python hl_lines="1  20"
        {!> ../../../docs_src/extra_models/tutorial004.py!}
        ```
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Mon Apr 01 01:15:53 GMT 2024
    - 6.7K bytes
    - Viewed (0)
  6. docs/de/docs/tutorial/extra-models.md

    Genauso können Sie eine Response deklarieren, die eine Liste von Objekten ist.
    
    Verwenden Sie dafür Pythons Standard `typing.List` (oder nur `list` in Python 3.9 und darüber):
    
    === "Python 3.9+"
    
        ```Python hl_lines="18"
        {!> ../../../docs_src/extra_models/tutorial004_py39.py!}
        ```
    
    === "Python 3.8+"
    
        ```Python hl_lines="1  20"
        {!> ../../../docs_src/extra_models/tutorial004.py!}
        ```
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Sat Mar 30 20:26:47 GMT 2024
    - 8.7K bytes
    - Viewed (0)
  7. docs/ja/docs/tutorial/extra-models.md

    ```
    
    ## 任意の`dict`を持つレスポンス
    
    また、Pydanticモデルを使用せずに、キーと値の型だけを定義した任意の`dict`を使ってレスポンスを宣言することもできます。
    
    これは、有効なフィールド・属性名(Pydanticモデルに必要なもの)を事前に知らない場合に便利です。
    
    この場合、`typing.Dict`を使用することができます:
    
    ```Python hl_lines="1 8"
    {!../../../docs_src/extra_models/tutorial005.py!}
    ```
    
    ## まとめ
    
    複数のPydanticモデルを使用し、ケースごとに自由に継承します。
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Mon Jan 15 15:36:32 GMT 2024
    - 6.7K bytes
    - Viewed (0)
Back to top