- Sort Score
- Result 10 results
- Languages All
Results 151 - 160 of 922 for Optional (0.17 sec)
-
compat/maven-compat/src/test/java/org/apache/maven/SimpleLookup.java
public <T> T lookup(Class<T> type, String name) { return null; } @Override public <T> Optional<T> lookupOptional(Class<T> type) { return Optional.empty(); } @Override public <T> Optional<T> lookupOptional(Class<T> type, String name) { return Optional.empty(); } @Override public <T> List<T> lookupList(Class<T> type) { return List.of(); }
Registered: Sun Nov 03 03:35:11 UTC 2024 - Last Modified: Fri Oct 25 12:31:46 UTC 2024 - 2K bytes - Viewed (0) -
guava/src/com/google/common/collect/Streams.java
* * <p><b>Java 9 users:</b> use {@code optional.stream()} instead. */ @Beta @InlineMe(replacement = "optional.stream()") @InlineMeValidationDisabled("Java 9+ API only") public static <T> Stream<T> stream(java.util.Optional<T> optional) { return optional.isPresent() ? Stream.of(optional.get()) : Stream.empty(); } /** * If a value is present in {@code optional}, returns a stream containing only that element,
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Thu Oct 31 14:20:11 UTC 2024 - 36.8K bytes - Viewed (0) -
apache-maven/src/assembly/maven/bin/mvnenc
# Apache Maven Encrypt Script # # Environment Variable Prerequisites # # JAVA_HOME (Optional) Points to a Java installation. # MAVEN_OPTS (Optional) Java runtime options used when Maven is executed. # MAVEN_SKIP_RC (Optional) Flag to disable loading of mavenrc files. # -----------------------------------------------------------------------------
Registered: Sun Nov 03 03:35:11 UTC 2024 - Last Modified: Fri Oct 18 11:01:21 UTC 2024 - 1.3K bytes - Viewed (0) -
common-protos/k8s.io/apimachinery/pkg/util/intstr/generated.proto
// TODO: Rename to Int32OrString // // +protobuf=true // +protobuf.options.(gogoproto.goproto_stringer)=false // +k8s:openapi-gen=true message IntOrString { optional int64 type = 1; optional int32 intVal = 2; optional string strVal = 3;
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Mon Mar 11 18:43:24 UTC 2024 - 1.3K bytes - Viewed (0) -
fastapi/utils.py
def create_model_field( name: str, type_: Any, class_validators: Optional[Dict[str, Validator]] = None, default: Optional[Any] = Undefined, required: Union[bool, UndefinedType] = Undefined, model_config: Type[BaseConfig] = BaseConfig, field_info: Optional[FieldInfo] = None, alias: Optional[str] = None, mode: Literal["validation", "serialization"] = "validation", ) -> ModelField:
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat Aug 31 23:46:03 UTC 2024 - 7.8K bytes - Viewed (0) -
tests/test_security_api_key_header_optional.py
from typing import Optional from fastapi import Depends, FastAPI, Security from fastapi.security import APIKeyHeader from fastapi.testclient import TestClient from pydantic import BaseModel app = FastAPI() api_key = APIKeyHeader(name="key", auto_error=False) class User(BaseModel): username: str def get_current_user(oauth_header: Optional[str] = Security(api_key)): if oauth_header is None: return None
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 2K bytes - Viewed (0) -
tests/test_validate_response.py
from typing import List, Optional, Union import pytest from fastapi import FastAPI from fastapi.exceptions import ResponseValidationError from fastapi.testclient import TestClient from pydantic import BaseModel app = FastAPI() class Item(BaseModel): name: str price: Optional[float] = None owner_ids: Optional[List[int]] = None @app.get("/items/invalid", response_model=Item) def get_invalid():
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jul 07 17:12:13 UTC 2023 - 2K bytes - Viewed (0) -
tests/test_security_openid_connect_optional.py
from typing import Optional from fastapi import Depends, FastAPI, Security from fastapi.security.open_id_connect_url import OpenIdConnect from fastapi.testclient import TestClient from pydantic import BaseModel app = FastAPI() oid = OpenIdConnect(openIdConnectUrl="/openid", auto_error=False) class User(BaseModel): username: str def get_current_user(oauth_header: Optional[str] = Security(oid)): if oauth_header is None:
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 2.4K bytes - Viewed (0) -
tests/test_enforce_once_required_parameter.py
from typing import Optional from fastapi import Depends, FastAPI, Query, status from fastapi.testclient import TestClient app = FastAPI() def _get_client_key(client_id: str = Query(...)) -> str: return f"{client_id}_key" def _get_client_tag(client_id: Optional[str] = Query(None)) -> Optional[str]: if client_id is None: return None return f"{client_id}_tag" @app.get("/foo") def foo_handler(
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 3.4K bytes - Viewed (0) -
impl/maven-core/src/main/java/org/apache/maven/internal/impl/DefaultArtifactManager.java
return Optional.of(project.getArtifact().getFile().toPath()); } } } Path path = paths.get(id); if (path == null && artifact instanceof DefaultArtifact) { path = ((DefaultArtifact) artifact).getArtifact().getPath(); } return Optional.ofNullable(path); } @Override
Registered: Sun Nov 03 03:35:11 UTC 2024 - Last Modified: Fri Oct 25 12:31:46 UTC 2024 - 4K bytes - Viewed (0)