Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for syntax (0.29 sec)

  1. docs/de/docs/tutorial/body-nested-models.md

    In Python 3.9 wäre das:
    
    ```Python
    my_list: list[str]
    ```
    
    Und in Python-Versionen vor 3.9:
    
    ```Python
    from typing import List
    
    my_list: List[str]
    ```
    
    Das ist alles Standard-Python-Syntax für Typdeklarationen.
    
    Verwenden Sie dieselbe Standardsyntax für Modellattribute mit inneren Typen.
    
    In unserem Beispiel können wir also bewirken, dass `tags` spezifisch eine „Liste von Strings“ ist:
    
    === "Python 3.10+"
    Plain Text
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Fri Mar 22 01:42:11 GMT 2024
    - 10.4K bytes
    - Viewed (0)
  2. docs/pt/docs/tutorial/body-nested-models.md

    * Passe o(s) tipo(s) interno(s) como "parâmetros de tipo" usando colchetes: `[` e `]`
    
    ```Python
    from typing import List
    
    my_list: List[str]
    ```
    
    Essa é a sintaxe padrão do Python para declarações de tipo.
    
    Use a mesma sintaxe padrão para atributos de modelo com tipos internos.
    
    Portanto, em nosso exemplo, podemos fazer com que `tags` sejam especificamente uma "lista de strings":
    
    
    ```Python hl_lines="14"
    Plain Text
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Thu Apr 18 19:53:19 GMT 2024
    - 7.4K bytes
    - Viewed (0)
  3. docs/en/docs/tutorial/body-nested-models.md

    ```Python
    my_list: list[str]
    ```
    
    In versions of Python before 3.9, it would be:
    
    ```Python
    from typing import List
    
    my_list: List[str]
    ```
    
    That's all standard Python syntax for type declarations.
    
    Use that same standard syntax for model attributes with internal types.
    
    So, in our example, we can make `tags` be specifically a "list of strings":
    
    === "Python 3.10+"
    
        ```Python hl_lines="12"
    Plain Text
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Fri Mar 22 01:42:11 GMT 2024
    - 9.5K bytes
    - Viewed (0)
Back to top