pub struct PostgresConnection { /* private fields */ }Trait Implementations§
Source§impl DbConnection for PostgresConnection
impl DbConnection for PostgresConnection
Source§fn get_expired_timers<'life0, 'async_trait>(
&'life0 self,
at: DateTime<Utc>,
) -> Pin<Box<dyn Future<Output = Result<Vec<ExpiredTimer>, DbErrorGeneric>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_expired_timers<'life0, 'async_trait>(
&'life0 self,
at: DateTime<Utc>,
) -> Pin<Box<dyn Future<Output = Result<Vec<ExpiredTimer>, DbErrorGeneric>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Get currently expired delays and locks.
Source§fn create<'life0, 'async_trait>(
&'life0 self,
req: CreateRequest,
) -> Pin<Box<dyn Future<Output = Result<AppendResponse, DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn create<'life0, 'async_trait>(
&'life0 self,
req: CreateRequest,
) -> Pin<Box<dyn Future<Output = Result<AppendResponse, DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Create a new execution log
Source§fn get<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
) -> Pin<Box<dyn Future<Output = Result<ExecutionLog, DbErrorRead>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
) -> Pin<Box<dyn Future<Output = Result<ExecutionLog, DbErrorRead>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Get execution log.
Source§fn append_batch<'life0, 'async_trait>(
&'life0 self,
current_time: DateTime<Utc>,
batch: Vec<AppendRequest>,
execution_id: ExecutionId,
version: Version,
) -> Pin<Box<dyn Future<Output = Result<AppendBatchResponse, DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn append_batch<'life0, 'async_trait>(
&'life0 self,
current_time: DateTime<Utc>,
batch: Vec<AppendRequest>,
execution_id: ExecutionId,
version: Version,
) -> Pin<Box<dyn Future<Output = Result<AppendBatchResponse, DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Append a batch of events to an existing execution log, and append a response to a parent execution.
The batch cannot contain
ExecutionEventInner::Created.Source§fn append_batch_create_new_execution<'life0, 'async_trait>(
&'life0 self,
current_time: DateTime<Utc>,
batch: Vec<AppendRequest>,
execution_id: ExecutionId,
version: Version,
child_req: Vec<CreateRequest>,
backtraces: Vec<BacktraceInfo>,
) -> Pin<Box<dyn Future<Output = Result<AppendBatchResponse, DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn append_batch_create_new_execution<'life0, 'async_trait>(
&'life0 self,
current_time: DateTime<Utc>,
batch: Vec<AppendRequest>,
execution_id: ExecutionId,
version: Version,
child_req: Vec<CreateRequest>,
backtraces: Vec<BacktraceInfo>,
) -> Pin<Box<dyn Future<Output = Result<AppendBatchResponse, DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Append one or more events to the parent execution log, and create zero or more child execution logs.
The batch cannot contain
ExecutionEventInner::Created.Source§fn subscribe_to_next_responses<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
last_response: ResponseCursor,
timeout_fut: Pin<Box<dyn Future<Output = TimeoutOutcome> + Send>>,
) -> Pin<Box<dyn Future<Output = Result<Vec<ResponseWithCursor>, DbErrorReadWithTimeout>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn subscribe_to_next_responses<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
last_response: ResponseCursor,
timeout_fut: Pin<Box<dyn Future<Output = TimeoutOutcome> + Send>>,
) -> Pin<Box<dyn Future<Output = Result<Vec<ResponseWithCursor>, DbErrorReadWithTimeout>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Notification mechainism with no strict guarantees for getting notified when a new response arrives.
Parameter
start_idx must be at most be equal to current size of responses in the execution log.
If no response arrives immediately and interrupt_after resolves, DbErrorReadWithTimeout::Timeout is returned.
Implementations with no pubsub support should use polling.
Callers are expected to call this function in a loop with a reasonable timeout
to support less stellar implementations.Source§fn wait_for_finished_result<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
timeout_fut: Option<Pin<Box<dyn Future<Output = TimeoutOutcome> + Send>>>,
) -> Pin<Box<dyn Future<Output = Result<SupportedFunctionReturnValue, DbErrorReadWithTimeout>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn wait_for_finished_result<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
timeout_fut: Option<Pin<Box<dyn Future<Output = TimeoutOutcome> + Send>>>,
) -> Pin<Box<dyn Future<Output = Result<SupportedFunctionReturnValue, DbErrorReadWithTimeout>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
First, attempt to fetch the finished value. If the execution is not finished yet, poll
periodically or subscribe to db changes, racing with
timeout_fut.
Notification mechainism with no strict guarantees for getting the finished result.
Implementations with no pubsub support should use polling.
Callers are expected to call this function in a loop with a reasonable timeout
to support less stellar implementations.fn append_delay_response<'life0, 'async_trait>(
&'life0 self,
created_at: DateTime<Utc>,
execution_id: ExecutionId,
join_set_id: JoinSetId,
delay_id: DelayId,
result: Result<(), ()>,
) -> Pin<Box<dyn Future<Output = Result<AppendDelayResponseOutcome, DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn append_backtrace<'life0, 'async_trait>(
&'life0 self,
append: BacktraceInfo,
) -> Pin<Box<dyn Future<Output = Result<(), DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn append_backtrace_batch<'life0, 'async_trait>(
&'life0 self,
batch: Vec<BacktraceInfo>,
) -> Pin<Box<dyn Future<Output = Result<(), DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn append_log<'life0, 'async_trait>(
&'life0 self,
row: LogInfoAppendRow,
) -> Pin<Box<dyn Future<Output = Result<(), DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn append_log_batch<'life0, 'life1, 'async_trait>(
&'life0 self,
batch: &'life1 [LogInfoAppendRow],
) -> Pin<Box<dyn Future<Output = Result<(), DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Source§fn get_execution_event<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
version: &'life2 Version,
) -> Pin<Box<dyn Future<Output = Result<ExecutionEvent, DbErrorRead>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn get_execution_event<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
version: &'life2 Version,
) -> Pin<Box<dyn Future<Output = Result<ExecutionEvent, DbErrorRead>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Get a single event specified by version. Impls may set
ExecutionEvent::backtrace_id to None.fn get_pending_state<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
) -> Pin<Box<dyn Future<Output = Result<ExecutionWithState, DbErrorRead>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_create_request<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
) -> Pin<Box<dyn Future<Output = Result<CreateRequest, DbErrorRead>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: Sync + 'async_trait,
Source§impl DbExecutor for PostgresConnection
impl DbExecutor for PostgresConnection
fn lock_pending_by_ffqns<'life0, 'async_trait>(
&'life0 self,
batch_size: u32,
pending_at_or_sooner: DateTime<Utc>,
ffqns: Arc<[FunctionFqn]>,
created_at: DateTime<Utc>,
component_id: ComponentId,
deployment_id: DeploymentId,
executor_id: ExecutorId,
lock_expires_at: DateTime<Utc>,
run_id: RunId,
retry_config: ComponentRetryConfig,
) -> Pin<Box<dyn Future<Output = Result<LockPendingResponse, DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn lock_pending_by_component_digest<'life0, 'life1, 'async_trait>(
&'life0 self,
batch_size: u32,
pending_at_or_sooner: DateTime<Utc>,
component_id: &'life1 ComponentId,
deployment_id: DeploymentId,
created_at: DateTime<Utc>,
executor_id: ExecutorId,
lock_expires_at: DateTime<Utc>,
run_id: RunId,
retry_config: ComponentRetryConfig,
) -> Pin<Box<dyn Future<Output = Result<LockPendingResponse, DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Source§fn append<'life0, 'async_trait>(
&'life0 self,
execution_id: ExecutionId,
version: Version,
req: AppendRequest,
) -> Pin<Box<dyn Future<Output = Result<AppendResponse, DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn append<'life0, 'async_trait>(
&'life0 self,
execution_id: ExecutionId,
version: Version,
req: AppendRequest,
) -> Pin<Box<dyn Future<Output = Result<AppendResponse, DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Append a single event to an existing execution log.
The request cannot contain
ExecutionEventInner::Created.Source§fn append_batch_respond_to_parent<'life0, 'async_trait>(
&'life0 self,
events: AppendEventsToExecution,
response: AppendResponseToExecution,
current_time: DateTime<Utc>,
) -> Pin<Box<dyn Future<Output = Result<AppendBatchResponse, DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn append_batch_respond_to_parent<'life0, 'async_trait>(
&'life0 self,
events: AppendEventsToExecution,
response: AppendResponseToExecution,
current_time: DateTime<Utc>,
) -> Pin<Box<dyn Future<Output = Result<AppendBatchResponse, DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Append a batch of events to an existing execution log, and append a response to a parent execution.
The batch cannot contain
ExecutionEventInner::Created.Source§fn wait_for_pending_by_ffqn<'life0, 'async_trait>(
&'life0 self,
pending_at_or_sooner: DateTime<Utc>,
ffqns: Arc<[FunctionFqn]>,
timeout_fut: Pin<Box<dyn Future<Output = ()> + Send>>,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn wait_for_pending_by_ffqn<'life0, 'async_trait>(
&'life0 self,
pending_at_or_sooner: DateTime<Utc>,
ffqns: Arc<[FunctionFqn]>,
timeout_fut: Pin<Box<dyn Future<Output = ()> + Send>>,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Notification mechainism with no strict guarantees for waiting while there are no pending executions.
Return immediately if there are pending notifications at
pending_at_or_sooner.
Otherwise wait until timeout_fut resolves.
Delay requests that expire between pending_at_or_sooner and timeout can be disregarded.Source§fn wait_for_pending_by_component_digest<'life0, 'life1, 'async_trait>(
&'life0 self,
pending_at_or_sooner: DateTime<Utc>,
component_digest: &'life1 InputContentDigest,
timeout_fut: Pin<Box<dyn Future<Output = ()> + Send>>,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn wait_for_pending_by_component_digest<'life0, 'life1, 'async_trait>(
&'life0 self,
pending_at_or_sooner: DateTime<Utc>,
component_digest: &'life1 InputContentDigest,
timeout_fut: Pin<Box<dyn Future<Output = ()> + Send>>,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Notification mechainism with no strict guarantees for waiting while there are no pending executions.
Return immediately if there are pending notifications at
pending_at_or_sooner.
Otherwise wait until timeout_fut resolves.
Delay requests that expire between pending_at_or_sooner and timeout can be disregarded.Source§fn get_last_execution_event<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
) -> Pin<Box<dyn Future<Output = Result<ExecutionEvent, DbErrorRead>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_last_execution_event<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
) -> Pin<Box<dyn Future<Output = Result<ExecutionEvent, DbErrorRead>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Get last event. Impls may set
ExecutionEvent::backtrace_id to None.fn cancel_activity_with_retries<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
cancelled_at: DateTime<Utc>,
) -> Pin<Box<dyn Future<Output = Result<CancelOutcome, DbErrorWrite>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
fn cancel_activity<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
cancelled_at: DateTime<Utc>,
) -> Pin<Box<dyn Future<Output = Result<CancelOutcome, DbErrorWrite>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
Source§impl DbExternalApi for PostgresConnection
impl DbExternalApi for PostgresConnection
Source§fn get_backtrace<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
filter: BacktraceFilter,
) -> Pin<Box<dyn Future<Output = Result<BacktraceInfo, DbErrorRead>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_backtrace<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
filter: BacktraceFilter,
) -> Pin<Box<dyn Future<Output = Result<BacktraceInfo, DbErrorRead>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Get the latest backtrace if version is not set.
Source§fn list_executions<'life0, 'async_trait>(
&'life0 self,
filter: ListExecutionsFilter,
pagination: ExecutionListPagination,
) -> Pin<Box<dyn Future<Output = Result<Vec<ExecutionWithState>, DbErrorGeneric>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn list_executions<'life0, 'async_trait>(
&'life0 self,
filter: ListExecutionsFilter,
pagination: ExecutionListPagination,
) -> Pin<Box<dyn Future<Output = Result<Vec<ExecutionWithState>, DbErrorGeneric>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Returns executions sorted in descending order.
Source§fn list_execution_events<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
pagination: Pagination<VersionType>,
include_backtrace_id: bool,
) -> Pin<Box<dyn Future<Output = Result<ListExecutionEventsResponse, DbErrorRead>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn list_execution_events<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
pagination: Pagination<VersionType>,
include_backtrace_id: bool,
) -> Pin<Box<dyn Future<Output = Result<ListExecutionEventsResponse, DbErrorRead>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Returns execution events for the given execution. Read more
Source§fn list_responses<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
pagination: Pagination<u32>,
) -> Pin<Box<dyn Future<Output = Result<ListResponsesResponse, DbErrorRead>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn list_responses<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
pagination: Pagination<u32>,
) -> Pin<Box<dyn Future<Output = Result<ListResponsesResponse, DbErrorRead>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Returns responses of an execution ordered as they arrived,
enabling matching each
JoinNext to its corresponding response. Read morefn list_execution_events_responses<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
req_since: &'life2 Version,
req_max_length: VersionType,
req_include_backtrace_id: bool,
resp_pagination: Pagination<u32>,
) -> Pin<Box<dyn Future<Output = Result<ExecutionWithStateRequestsResponses, DbErrorRead>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn upgrade_execution_component<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
old: &'life2 InputContentDigest,
new: &'life3 InputContentDigest,
) -> Pin<Box<dyn Future<Output = Result<(), DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
fn list_logs<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
filter: LogFilter,
pagination: Pagination<u32>,
) -> Pin<Box<dyn Future<Output = Result<ListLogsResponse, DbErrorRead>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn list_deployment_states<'life0, 'async_trait>(
&'life0 self,
current_time: DateTime<Utc>,
pagination: Pagination<Option<DeploymentId>>,
) -> Pin<Box<dyn Future<Output = Result<Vec<DeploymentState>, DbErrorRead>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn pause_execution<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
paused_at: DateTime<Utc>,
) -> Pin<Box<dyn Future<Output = Result<AppendResponse, DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn pause_execution<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
paused_at: DateTime<Utc>,
) -> Pin<Box<dyn Future<Output = Result<AppendResponse, DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Pause an execution. Only pending executions can be paused.
Source§fn unpause_execution<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
unpaused_at: DateTime<Utc>,
) -> Pin<Box<dyn Future<Output = Result<AppendResponse, DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn unpause_execution<'life0, 'life1, 'async_trait>(
&'life0 self,
execution_id: &'life1 ExecutionId,
unpaused_at: DateTime<Utc>,
) -> Pin<Box<dyn Future<Output = Result<AppendResponse, DbErrorWrite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Unpause an execution. Only paused executions can be unpaused.
Auto Trait Implementations§
impl !Freeze for PostgresConnection
impl !RefUnwindSafe for PostgresConnection
impl Send for PostgresConnection
impl Sync for PostgresConnection
impl Unpin for PostgresConnection
impl !UnwindSafe for PostgresConnection
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more