- Sort Score
- Num 10 results
- Language All
Results 101 - 110 of 349 for unionOf (0.05 seconds)
-
docs_src/header_params/tutorial003_py39.py
from typing import Union from fastapi import FastAPI, Header app = FastAPI() @app.get("/items/") async def read_items(x_token: Union[list[str], None] = Header(default=None)):
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Sat May 14 11:59:59 GMT 2022 - 218 bytes - Click Count (0) -
docs_src/query_params_str_validations/tutorial011_an_py39.py
from typing import Annotated, Union from fastapi import FastAPI, Query app = FastAPI() @app.get("/items/") async def read_items(q: Annotated[Union[list[str], None], Query()] = None): query_items = {"q": q}
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Sat Mar 18 12:29:59 GMT 2023 - 237 bytes - Click Count (0) -
docs_src/request_files/tutorial001_02_py39.py
from typing import Union from fastapi import FastAPI, File, UploadFile app = FastAPI() @app.post("/files/") async def create_file(file: Union[bytes, None] = File(default=None)): if not file: return {"message": "No file sent"} else: return {"file_size": len(file)} @app.post("/uploadfile/") async def create_upload_file(file: Union[UploadFile, None] = None): if not file:
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Wed Dec 17 20:41:43 GMT 2025 - 508 bytes - Click Count (0) -
docs_src/query_params/tutorial002_py39.py
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Wed Dec 17 20:41:43 GMT 2025 - 251 bytes - Click Count (0) -
fastapi/_compat/v2.py
name: str mode: Literal["validation", "serialization"] = "validation" config: Union[ConfigDict, None] = None @property def alias(self) -> str: a = self.field_info.alias return a if a is not None else self.name @property def validation_alias(self) -> Union[str, None]: va = self.field_info.validation_alias if isinstance(va, str) and va:Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Sat Dec 27 12:54:56 GMT 2025 - 19.1K bytes - Click Count (0) -
docs_src/query_params_str_validations/tutorial014_an_py39.py
from typing import Annotated, Union from fastapi import FastAPI, Query app = FastAPI() @app.get("/items/") async def read_items( hidden_query: Annotated[Union[str, None], Query(include_in_schema=False)] = None, ): if hidden_query: return {"hidden_query": hidden_query} else:
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Tue Mar 26 16:56:53 GMT 2024 - 344 bytes - Click Count (0) -
docs_src/pydantic_v1_in_v2/tutorial002_an_py39.py
from typing import Union from fastapi import FastAPI from pydantic.v1 import BaseModel class Item(BaseModel): name: str description: Union[str, None] = None size: float app = FastAPI() @app.post("/items/") async def create_item(item: Item) -> Item:
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Wed Dec 17 20:41:43 GMT 2025 - 284 bytes - Click Count (0) -
docs_src/query_params_str_validations/tutorial009_py39.py
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Wed Dec 17 20:41:43 GMT 2025 - 313 bytes - Click Count (0) -
docs_src/sql_databases/tutorial001_an_py39.py
from typing import Annotated, Union from fastapi import Depends, FastAPI, HTTPException, Query from sqlmodel import Field, Session, SQLModel, create_engine, select class Hero(SQLModel, table=True): id: Union[int, None] = Field(default=None, primary_key=True) name: str = Field(index=True) age: Union[int, None] = Field(default=None, index=True) secret_name: str sqlite_file_name = "database.db"
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Wed Oct 09 19:44:42 GMT 2024 - 1.7K bytes - Click Count (0) -
internal/config/lambda/event/targetidset.go
maps.Copy(setCopy, set) return setCopy } // add - adds TargetID to the set. func (set TargetIDSet) add(targetID TargetID) { set[targetID] = struct{}{} } // Union - returns union with given set as new set. func (set TargetIDSet) Union(sset TargetIDSet) TargetIDSet { nset := set.Clone() for k := range sset { nset.add(k) } return nset }
Created: Sun Dec 28 19:28:13 GMT 2025 - Last Modified: Fri Aug 29 02:39:48 GMT 2025 - 1.9K bytes - Click Count (0)