- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 999 for isInstance (0.1 sec)
-
fastapi/dependencies/utils.py
) -> Dependant: security_requirement = None security_scopes = security_scopes or [] if isinstance(depends, params.Security): dependency_scopes = depends.scopes security_scopes.extend(dependency_scopes) if isinstance(dependency, SecurityBase): use_scopes: List[str] = [] if isinstance(dependency, (OAuth2, OpenIdConnect)): use_scopes = security_scopes
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 27 21:46:26 UTC 2024 - 34.7K bytes - Viewed (0) -
fastapi/encoders.py
sqlalchemy_safe=sqlalchemy_safe, ) if isinstance(obj, Enum): return obj.value if isinstance(obj, PurePath): return str(obj) if isinstance(obj, (str, int, float, type(None))): return obj if isinstance(obj, UndefinedType): return None if isinstance(obj, dict): encoded_dict = {} allowed_keys = set(obj.keys())
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Thu Apr 18 21:56:59 UTC 2024 - 10.8K bytes - Viewed (0) -
scripts/mkdocs_hooks.py
for item in items: if isinstance(item, str): resolve_file(item=item, files=files, config=config) elif isinstance(item, dict): assert len(item) == 1 values = list(item.values()) if not values: continue if isinstance(values[0], str): resolve_file(item=values[0], files=files, config=config)
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat Aug 17 21:20:31 UTC 2024 - 5.2K bytes - Viewed (0) -
fastapi/utils.py
if ( key in main_dict and isinstance(main_dict[key], dict) and isinstance(value, dict) ): deep_dict_update(main_dict[key], value) elif ( key in main_dict and isinstance(main_dict[key], list) and isinstance(update_dict[key], list) ):
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat Aug 31 23:46:03 UTC 2024 - 7.8K bytes - Viewed (0) -
fastapi/openapi/utils.py
callback_flat_models: List[ModelField] = [] for route in routes: if getattr(route, "include_in_schema", None) and isinstance( route, routing.APIRoute ): if route.body_field: assert isinstance( route.body_field, ModelField ), "A request body must be a Pydantic Field"
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Tue Sep 17 18:54:10 UTC 2024 - 22.6K bytes - Viewed (0) -
tests/test_inherited_custom_class.py
from pydantic import field_serializer app = FastAPI() @app.get("/fast_uuid") def return_fast_uuid(): asyncpg_uuid = MyUuid("a10ff360-3b1e-4984-a26f-d3ab460bdb51") assert isinstance(asyncpg_uuid, uuid.UUID) assert type(asyncpg_uuid) is not uuid.UUID with pytest.raises(TypeError): vars(asyncpg_uuid) return {"fast_uuid": asyncpg_uuid}
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat Aug 17 04:13:50 UTC 2024 - 3K bytes - Viewed (0) -
src/test/java/org/codelibs/core/lang/GenericsUtilTest.java
final Type t3 = m3.getGenericReturnType(); assertThat(GenericsUtil.isTypeOf(t3, Map.class), is(true)); assertThat(WildcardType.class.isInstance(GenericsUtil.getKeyTypeOfMap(t3)), is(true)); assertThat(WildcardType.class.isInstance(GenericsUtil.getValueTypeOfMap(t3)), is(true)); } /** * @throws Exception */ public void testGetTypeVariableMap() throws Exception {
Registered: Fri Nov 01 20:58:10 UTC 2024 - Last Modified: Thu Mar 07 01:59:08 UTC 2024 - 11.5K bytes - Viewed (0) -
fastapi/datastructures.py
@classmethod def validate(cls: Type["UploadFile"], v: Any) -> Any: if not isinstance(v, StarletteUploadFile): raise ValueError(f"Expected UploadFile, received: {type(v)}") return v @classmethod def _validate(cls, __input_value: Any, _: Any) -> "UploadFile": if not isinstance(__input_value, StarletteUploadFile):
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Tue Apr 02 02:48:51 UTC 2024 - 5.6K bytes - Viewed (0) -
docs_src/sql_databases_peewee/sql_app/schemas.py
from pydantic import BaseModel from pydantic.utils import GetterDict class PeeweeGetterDict(GetterDict): def get(self, key: Any, default: Any = None): res = getattr(self._obj, key, default) if isinstance(res, peewee.ModelSelect): return list(res) return res class ItemBase(BaseModel): title: str description: Union[str, None] = None class ItemCreate(ItemBase): pass
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat May 14 11:59:59 UTC 2022 - 868 bytes - Viewed (0) -
android/guava/src/com/google/common/util/concurrent/Platform.java
@GwtCompatible(emulated = true) @ElementTypesAreNonnullByDefault final class Platform { static boolean isInstanceOfThrowableClass( @CheckForNull Throwable t, Class<? extends Throwable> expectedClass) { return expectedClass.isInstance(t); } static void restoreInterruptIfIsInterruptedException(Throwable t) { checkNotNull(t); // to satisfy NullPointerTester if (t instanceof InterruptedException) { currentThread().interrupt();
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Tue May 10 12:27:25 UTC 2022 - 1.4K bytes - Viewed (0)