Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 191 - 200 of 445 for item_1 (0.04 seconds)

  1. docs/ja/docs/tutorial/path-params.md

    Pythonのformat文字列と同様のシンタックスで「パスパラメータ」や「パス変数」を宣言できます:
    
    {* ../../docs_src/path_params/tutorial001_py310.py hl[6:7] *}
    
    パスパラメータ `item_id` の値は、引数 `item_id` として関数に渡されます。
    
    したがって、この例を実行して [http://127.0.0.1:8000/items/foo](http://127.0.0.1:8000/items/foo) にアクセスすると、次のレスポンスが表示されます。
    
    ```JSON
    {"item_id":"foo"}
    ```
    
    ## 型付きパスパラメータ { #path-parameters-with-types }
    
    標準のPythonの型アノテーションを使用して、関数内のパスパラメータの型を宣言できます:
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 14:07:17 GMT 2026
    - 10.8K bytes
    - Click Count (0)
  2. docs/ko/docs/tutorial/path-params-numeric-validations.md

    `Annotated`를 사용하기 전에 최소 0.95.1까지 [FastAPI 버전 업그레이드](../deployment/versions.md#upgrading-the-fastapi-versions)를 꼭 하세요.
    
    ///
    
    ## 메타데이터 선언 { #declare-metadata }
    
    `Query`에 동일한 매개변수를 선언할 수 있습니다.
    
    예를 들어, 경로 매개변수 `item_id`에 `title` 메타데이터 값을 선언하려면 다음과 같이 입력할 수 있습니다:
    
    {* ../../docs_src/path_params_numeric_validations/tutorial001_an_py310.py hl[10] *}
    
    /// note | 참고
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 14:06:26 GMT 2026
    - 7.2K bytes
    - Click Count (0)
  3. docs/zh/docs/tutorial/path-params-numeric-validations.md

    如果你使用的是更旧的版本,尝试使用 `Annotated` 会报错。
    
    请确保在使用 `Annotated` 之前,将 FastAPI 版本[升级](../deployment/versions.md#upgrading-the-fastapi-versions)到至少 0.95.1。
    
    ///
    
    ## 声明元数据 { #declare-metadata }
    
    你可以声明与 `Query` 相同的所有参数。
    
    例如,要为路径参数 `item_id` 声明 `title` 元数据值,你可以这样写:
    
    {* ../../docs_src/path_params_numeric_validations/tutorial001_an_py310.py hl[10] *}
    
    /// note | 注意
    
    路径参数总是必需的,因为它必须是路径的一部分。即使你将其声明为 `None` 或设置了默认值,也不会产生任何影响,它依然始终是必需参数。
    
    ///
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 17:06:37 GMT 2026
    - 6K bytes
    - Click Count (0)
  4. docs/de/docs/tutorial/handling-errors.md

    ### Die resultierende Response { #the-resulting-response }
    
    Wenn der Client `http://example.com/items/foo` anfordert (ein `item_id` `"foo"`), erhält dieser Client einen HTTP-Statuscode 200 und diese JSON-Response:
    
    ```JSON
    {
      "item": "The Foo Wrestlers"
    }
    ```
    
    Aber wenn der Client `http://example.com/items/bar` anfordert (ein nicht-existierendes `item_id` `"bar"`), erhält er einen HTTP-Statuscode 404 (der „Not Found“-Error) und eine JSON-Response wie:
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Thu Mar 19 17:58:09 GMT 2026
    - 10.3K bytes
    - Click Count (0)
  5. docs_src/custom_response/tutorial001b_py310.py

    from fastapi import FastAPI
    from fastapi.responses import ORJSONResponse
    
    app = FastAPI()
    
    
    @app.get("/items/", response_class=ORJSONResponse)
    async def read_items():
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Thu Feb 12 13:19:43 GMT 2026
    - 215 bytes
    - Click Count (0)
  6. src/test/java/org/codelibs/fess/util/WebApiUtilTest.java

                WebApiUtil.setObject("objectValue", new Object());
    
                // Test with collections
                java.util.List<String> list = java.util.Arrays.asList("item1", "item2");
                WebApiUtil.setObject("listValue", list);
    
                java.util.Map<String, String> map = new java.util.HashMap<>();
                map.put("key", "value");
    Created: Tue Mar 31 13:07:34 GMT 2026
    - Last Modified: Sun Jan 11 08:43:05 GMT 2026
    - 17.4K bytes
    - Click Count (0)
  7. docs/es/docs/tutorial/handling-errors.md

    ```JSON
    {
      "item": "The Foo Wrestlers"
    }
    ```
    
    Pero si el cliente solicita `http://example.com/items/bar` (un `item_id` inexistente `"bar"`), ese cliente recibirá un código de estado HTTP de 404 (el error "no encontrado"), y un response JSON de:
    
    ```JSON
    {
      "detail": "Item not found"
    }
    ```
    
    /// tip | Consejo
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Thu Mar 19 18:15:55 GMT 2026
    - 9.6K bytes
    - Click Count (0)
  8. docs/pt/docs/tutorial/handling-errors.md

    {
      "item": "The Foo Wrestlers"
    }
    ```
    
    Mas se o cliente faz uma requisição para `http://example.com/items/bar` (ou seja, um não existente `item_id "bar"`), esse cliente receberá um HTTP status code 404 (o erro "não encontrado" — *not found error*), e uma resposta JSON:
    
    ```JSON
    {
      "detail": "Item not found"
    }
    ```
    
    /// tip | Dica
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Thu Mar 19 18:20:43 GMT 2026
    - 10.1K bytes
    - Click Count (0)
  9. docs/zh-hant/docs/tutorial/path-params.md

    路徑參數 `item_id` 的值會作為引數 `item_id` 傳入你的函式。
    
    所以,如果你執行這個範例並前往 [http://127.0.0.1:8000/items/foo](http://127.0.0.1:8000/items/foo),你會看到這樣的回應:
    
    ```JSON
    {"item_id":"foo"}
    ```
    
    ## 具型別的路徑參數 { #path-parameters-with-types }
    
    你可以在函式中使用標準的 Python 型別註記為路徑參數宣告型別:
    
    {* ../../docs_src/path_params/tutorial002_py310.py hl[7] *}
    
    在這個例子裡,`item_id` 被宣告為 `int`。
    
    /// check
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 17:05:38 GMT 2026
    - 8.4K bytes
    - Click Count (0)
  10. tests/test_tutorial/test_additional_responses/test_tutorial001.py

    
    def test_path_operation():
        response = client.get("/items/foo")
        assert response.status_code == 200, response.text
        assert response.json() == {"id": "foo", "value": "there goes my hero"}
    
    
    def test_path_operation_not_found():
        response = client.get("/items/bar")
        assert response.status_code == 404, response.text
        assert response.json() == {"message": "Item not found"}
    
    
    def test_openapi_schema():
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Thu Feb 12 13:19:43 GMT 2026
    - 5.1K bytes
    - Click Count (0)
Back to Top