Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for attributes (0.15 sec)

  1. docs/pt/docs/tutorial/encoder.md

    Da mesma forma, este banco de dados não receberia um modelo Pydantic (um objeto com atributos), apenas um `dict`.
    
    Você pode usar a função `jsonable_encoder` para resolver isso.
    
    A função recebe um objeto, como um modelo Pydantic e retorna uma versão compatível com JSON:
    
    === "Python 3.10+"
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Thu Apr 18 19:53:19 GMT 2024
    - 1.9K bytes
    - Viewed (0)
  2. docs/en/docs/tutorial/encoder.md

    The same way, this database wouldn't receive a Pydantic model (an object with attributes), only a `dict`.
    
    You can use `jsonable_encoder` for that.
    
    It receives an object, like a Pydantic model, and returns a JSON compatible version:
    
    === "Python 3.10+"
    
        ```Python hl_lines="4  21"
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Tue Oct 17 05:59:11 GMT 2023
    - 1.8K bytes
    - Viewed (0)
  3. docs/de/docs/tutorial/encoder.md

    Genauso würde die Datenbank kein Pydantic-Modell (ein Objekt mit Attributen) akzeptieren, sondern nur ein `dict`.
    
    Sie können für diese Fälle `jsonable_encoder` verwenden.
    
    Es nimmt ein Objekt entgegen, wie etwa ein Pydantic-Modell, und gibt eine JSON-kompatible Version zurück:
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Sat Mar 30 18:07:21 GMT 2024
    - 1.9K bytes
    - Viewed (0)
Back to top