- Sort Score
- Num 10 results
- Language All
Results 211 - 220 of 1,155 for noneOf (0.04 seconds)
-
docs_src/cookie_param_models/tutorial001_an_py310.py
from typing import Annotated from fastapi import Cookie, FastAPI from pydantic import BaseModel app = FastAPI() class Cookies(BaseModel): session_id: str fatebook_tracker: str | None = None googall_tracker: str | None = None @app.get("/items/") async def read_items(cookies: Annotated[Cookies, Cookie()]):
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Tue Sep 17 18:54:10 GMT 2024 - 343 bytes - Click Count (0) -
tests/test_custom_middleware_exception.py
Args: app (ASGI application): ASGI application max_content_size (optional): the maximum content size allowed in bytes, None for no limit """ def __init__(self, app: APIRouter, max_content_size: int | None = None): self.app = app self.max_content_size = max_content_size def receive_wrapper(self, receive): received = 0 async def inner():Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Tue Feb 17 09:59:14 GMT 2026 - 2.8K bytes - Click Count (0) -
docs_src/query_params_str_validations/tutorial007_py310.py
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Tue Mar 26 16:56:53 GMT 2024 - 304 bytes - Click Count (0) -
docs_src/query_params_str_validations/tutorial002_an_py310.py
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Sat Mar 18 12:29:59 GMT 2023 - 309 bytes - Click Count (0) -
docs/zh/docs/tutorial/query-params-str-validations.md
由于这种情况下(不使用 `Annotated`)我们必须把函数中的默认值 `None` 替换为 `Query()`,因此需要通过参数 `Query(default=None)` 来设置默认值,它起到同样的作用(至少对 FastAPI 来说)。 所以: ```Python q: str | None = Query(default=None) ``` ...会让参数变成可选,默认值为 `None`,等同于: ```Python q: str | None = None ``` 但使用 `Query` 的版本会显式把它声明为一个查询参数。 然后,我们可以向 `Query` 传入更多参数。本例中是适用于字符串的 `max_length` 参数:
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri Mar 20 17:06:37 GMT 2026 - 15.4K bytes - Click Count (0) -
compat/maven-settings-builder/src/main/java/org/apache/maven/settings/building/SettingsBuildingRequest.java
*/ @Deprecated(since = "4.0.0") public interface SettingsBuildingRequest { /** * Gets the global settings file. * * @return The global settings file or {@code null} if none. */ File getGlobalSettingsFile(); /** * Sets the global settings file. A non-existent settings file is equivalent to empty settings. If both userCreated: Sun Apr 05 03:35:12 GMT 2026 - Last Modified: Fri Oct 25 12:31:46 GMT 2024 - 6K bytes - Click Count (0) -
tests/test_query.py
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Sat Dec 27 18:19:10 GMT 2025 - 7.4K bytes - Click Count (0) -
docs_src/body_multiple_params/tutorial005_an_py310.py
from typing import Annotated from fastapi import Body, FastAPI from pydantic import BaseModel app = FastAPI() class Item(BaseModel): name: str description: str | None = None price: float tax: float | None = None @app.put("/items/{item_id}") async def update_item(item_id: int, item: Annotated[Item, Body(embed=True)]): results = {"item_id": item_id, "item": item}
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Sat Mar 18 12:29:59 GMT 2023 - 409 bytes - Click Count (0) -
tests/test_openapi_separate_input_output_schemas.py
class SubItem(BaseModel): subname: str sub_description: str | None = None tags: list[str] = [] model_config = {"json_schema_serialization_defaults_required": True} class Item(BaseModel): name: str description: str | None = None sub: SubItem | None = None model_config = {"json_schema_serialization_defaults_required": True}
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Tue Feb 17 09:59:14 GMT 2026 - 27.8K bytes - Click Count (0) -
docs_src/schema_extra_example/tutorial003_py310.py
from fastapi import Body, FastAPI from pydantic import BaseModel app = FastAPI() class Item(BaseModel): name: str description: str | None = None price: float tax: float | None = None @app.put("/items/{item_id}") async def update_item( item_id: int, item: Item = Body( examples=[ { "name": "Foo", "description": "A very nice Item",
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri Jun 30 18:25:16 GMT 2023 - 574 bytes - Click Count (0)