Search Options

Results per page
Sort
Preferred Languages
Advance

Results 51 - 60 of 329 for declare (0.07 sec)

  1. docs/en/docs/reference/dependencies.md

    ```
    
    ::: fastapi.Depends
    
    ## `Security()`
    
    For many scenarios, you can handle security (authorization, authentication, etc.) with dependencies, using `Depends()`.
    
    But when you want to also declare OAuth2 scopes, you can use `Security()` instead of `Depends()`.
    
    You can import `Security()` directly from `fastapi`:
    
    ```python
    from fastapi import Security
    ```
    
    Registered: Sun Sep 07 07:19:17 UTC 2025
    - Last Modified: Thu Apr 18 19:53:19 UTC 2024
    - 671 bytes
    - Viewed (0)
  2. mockwebserver-junit4/README.md

    To use, first add this library as a test dependency:
    
    ```
    testImplementation("com.squareup.okhttp3:mockwebserver3-junit4:5.1.0")
    ```
    
    Then in tests annotated `@org.junit.Test`, you may declare a field with the `@Rule` annotation:
    
    ```
    @Rule public final MockWebServerRule serverRule = new MockWebServerRule();
    ```
    
    The `serverRule` field has a `server` field. It is an instance of `MockWebServer`. That instance
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Mon Jul 07 19:32:33 UTC 2025
    - 706 bytes
    - Viewed (0)
  3. docs/en/docs/reference/background.md

    # Background Tasks - `BackgroundTasks`
    
    You can declare a parameter in a *path operation function* or dependency function with the type `BackgroundTasks`, and then you can use it to schedule the execution of background tasks after the response is sent.
    
    You can import it directly from `fastapi`:
    
    ```python
    from fastapi import BackgroundTasks
    ```
    
    Registered: Sun Sep 07 07:19:17 UTC 2025
    - Last Modified: Thu Apr 18 19:53:19 UTC 2024
    - 377 bytes
    - Viewed (0)
  4. docs/es/docs/tutorial/dependencies/sub-dependencies.md

    Declara un parámetro de query opcional `q` como un `str`, y luego simplemente lo devuelve.
    
    Esto es bastante simple (no muy útil), pero nos ayudará a centrarnos en cómo funcionan las sub-dependencias.
    
    ## Segunda dependencia, "dependable" y "dependant"
    
    Luego puedes crear otra función de dependencia (un "dependable") que al mismo tiempo declare una dependencia propia (por lo que también es un "dependant"):
    Registered: Sun Sep 07 07:19:17 UTC 2025
    - Last Modified: Mon Dec 30 18:26:57 UTC 2024
    - 3.7K bytes
    - Viewed (0)
  5. docs/fr/docs/tutorial/path-params.md

    vous verrez comme réponse :
    
    ```JSON
    {"item_id":"foo"}
    ```
    
    ## Paramètres de chemin typés
    
    Vous pouvez déclarer le type d'un paramètre de chemin dans la fonction, en utilisant les annotations de type Python :
    
    
    {* ../../docs_src/path_params/tutorial002.py hl[7] *}
    
    Ici, `item_id` est déclaré comme `int`.
    
    /// check | vérifier
    
    Ceci vous permettra d'obtenir des fonctionnalités de l'éditeur dans votre fonction, telles
    Registered: Sun Sep 07 07:19:17 UTC 2025
    - Last Modified: Sat Nov 09 16:39:20 UTC 2024
    - 9.8K bytes
    - Viewed (0)
  6. docs/en/docs/reference/request.md

    # `Request` class
    
    You can declare a parameter in a *path operation function* or dependency to be of type `Request` and then you can access the raw request object directly, without any validation, etc.
    
    You can import it directly from `fastapi`:
    
    ```python
    from fastapi import Request
    ```
    
    /// tip
    
    Registered: Sun Sep 07 07:19:17 UTC 2025
    - Last Modified: Tue Aug 06 04:48:30 UTC 2024
    - 518 bytes
    - Viewed (0)
  7. docs/en/docs/reference/security/index.md

    # Security Tools
    
    When you need to declare dependencies with OAuth2 scopes you use `Security()`.
    
    But you still need to define what is the dependable, the callable that you pass as a parameter to `Depends()` or `Security()`.
    
    There are multiple tools that you can use to create those dependables, and they get integrated into OpenAPI so they are shown in the automatic docs UI, they can be used by automatically generated clients and SDKs, etc.
    
    Registered: Sun Sep 07 07:19:17 UTC 2025
    - Last Modified: Thu Apr 18 19:53:19 UTC 2024
    - 1.6K bytes
    - Viewed (0)
  8. docs/en/docs/tutorial/sql-databases.md

    Because each SQLModel model is also a Pydantic model, you can use it in the same **type annotations** that you could use Pydantic models.
    
    For example, if you declare a parameter of type `Hero`, it will be read from the **JSON body**.
    
    The same way, you can declare it as the function's **return type**, and then the shape of the data will show up in the automatic API docs UI.
    
    Registered: Sun Sep 07 07:19:17 UTC 2025
    - Last Modified: Sun Aug 31 09:15:41 UTC 2025
    - 15.4K bytes
    - Viewed (0)
  9. docs/en/docs/tutorial/bigger-applications.md

    ```Python hl_lines="1  3" title="app/routers/users.py"
    {!../../docs_src/bigger_applications/app/routers/users.py!}
    ```
    
    ### *Path operations* with `APIRouter` { #path-operations-with-apirouter }
    
    And then you use it to declare your *path operations*.
    
    Use it the same way you would use the `FastAPI` class:
    
    ```Python hl_lines="6  11  16" title="app/routers/users.py"
    {!../../docs_src/bigger_applications/app/routers/users.py!}
    ```
    
    Registered: Sun Sep 07 07:19:17 UTC 2025
    - Last Modified: Sun Aug 31 09:15:41 UTC 2025
    - 19.1K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/collect/EvictingQueue.java

      @J2ktIncompatible // Incompatible return type change. Use inherited implementation
      public Object[] toArray() {
        /*
         * If we could, we'd declare the no-arg `Collection.toArray()` to return "Object[] but elements
         * have the same nullness as E." Since we can't, we declare it to return nullable elements, and
         * we can override it in our non-null-guaranteeing subtypes to present a better signature to
         * their users.
         *
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Thu Feb 13 17:34:21 UTC 2025
    - 4.6K bytes
    - Viewed (0)
Back to top