pub struct ClosureHandler { /* private fields */ }Expand description
A CallHandler that delegates on_incoming_call to a closure.
Created by CallbackPeer::from_fn(). The closure receives a borrowed
IncomingCall for inspection and returns a CallHandlerDecision.
The peer applies that decision after the closure returns. Use
CallbackPeer::builder for async closure hooks, DTMF, ended, transfer,
or defer flows that need to own the IncomingCall.
Trait Implementations§
Source§impl CallHandler for ClosureHandler
impl CallHandler for ClosureHandler
Source§fn on_incoming_call<'life0, 'async_trait>(
&'life0 self,
call: IncomingCall,
) -> Pin<Box<dyn Future<Output = CallHandlerDecision> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_incoming_call<'life0, 'async_trait>(
&'life0 self,
call: IncomingCall,
) -> Pin<Box<dyn Future<Output = CallHandlerDecision> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Decide what to do with an incoming call. Read more
Source§fn on_event<'life0, 'async_trait>(
&'life0 self,
event: Event,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_event<'life0, 'async_trait>(
&'life0 self,
event: Event,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called for every event before the more specific callback hook.
Source§fn on_call_established<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_call_established<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when an outgoing or accepted incoming call is fully established.
Source§fn on_call_progress<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
status_code: u16,
reason: String,
sdp: Option<String>,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_call_progress<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
status_code: u16,
reason: String,
sdp: Option<String>,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when an outgoing call receives a provisional 1xx response. Read more
Source§fn on_call_ended<'life0, 'async_trait>(
&'life0 self,
call_id: CallId,
reason: EndReason,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_call_ended<'life0, 'async_trait>(
&'life0 self,
call_id: CallId,
reason: EndReason,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when any call (incoming or outgoing) ends.
Source§fn on_call_failed<'life0, 'async_trait>(
&'life0 self,
call_id: CallId,
status_code: u16,
reason: String,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_call_failed<'life0, 'async_trait>(
&'life0 self,
call_id: CallId,
status_code: u16,
reason: String,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when a call fails before normal BYE teardown.
Source§fn on_call_cancelled<'life0, 'async_trait>(
&'life0 self,
call_id: CallId,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_call_cancelled<'life0, 'async_trait>(
&'life0 self,
call_id: CallId,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when a ringing call is cancelled before answer.
Source§fn on_dtmf<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
digit: char,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_dtmf<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
digit: char,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when a DTMF digit is received on an active call.
Source§fn on_media_security_negotiated<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
state: MediaSecurityState,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_media_security_negotiated<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
state: MediaSecurityState,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when SRTP media security has been negotiated and contexts are installed. Read more
Source§fn on_call_on_hold<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_call_on_hold<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when a locally requested hold is accepted.
Source§fn on_call_resumed<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_call_resumed<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when a locally requested resume is accepted.
Source§fn on_remote_call_on_hold<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_remote_call_on_hold<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when the remote peer places this call on hold.
Source§fn on_remote_call_resumed<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_remote_call_resumed<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when the remote peer resumes this call.
Source§fn on_transfer_accepted<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
refer_to: String,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_transfer_accepted<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
refer_to: String,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when an outbound REFER is accepted by the peer.
Source§fn on_refer_notify<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
status_code: u16,
reason: String,
subscription_state: Option<SubscriptionState>,
body: Option<String>,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_refer_notify<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
status_code: u16,
reason: String,
subscription_state: Option<SubscriptionState>,
body: Option<String>,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when raw REFER NOTIFY status is received.
Source§fn on_refer_progress<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
status_code: u16,
reason: String,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_refer_progress<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
status_code: u16,
reason: String,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when provisional REFER progress NOTIFY is received.
Source§fn on_refer_completed<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
target: String,
status_code: u16,
reason: String,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_refer_completed<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
target: String,
status_code: u16,
reason: String,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when successful terminal REFER completion is received.
Source§fn on_transfer_failed<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
status_code: u16,
reason: String,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_transfer_failed<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
status_code: u16,
reason: String,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when REFER failure is received.
Source§fn on_transfer_target_answered<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
target_uri: String,
evidence: TransferTargetEvidence,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_transfer_target_answered<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
target_uri: String,
evidence: TransferTargetEvidence,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when rvoip-sip has target-answer evidence for a transfer.
Source§fn on_transfer_replacement_dialog_observed<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
dialog: DialogInfo,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_transfer_replacement_dialog_observed<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
dialog: DialogInfo,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when RFC 4235 observes a candidate replacement dialog.
Source§fn on_transfer_replacement_dialog_terminated<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
dialog: DialogInfo,
reason: Option<String>,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_transfer_replacement_dialog_terminated<'life0, 'async_trait>(
&'life0 self,
handle: SessionHandle,
dialog: DialogInfo,
reason: Option<String>,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when RFC 4235 or local evidence observes replacement dialog teardown.
Source§fn on_dialog_package_notify<'life0, 'async_trait>(
&'life0 self,
subscription_id: CallId,
entity: Option<String>,
version: Option<u32>,
dialogs: Vec<DialogInfo>,
document: DialogInfoDocument,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_dialog_package_notify<'life0, 'async_trait>(
&'life0 self,
subscription_id: CallId,
entity: Option<String>,
version: Option<u32>,
dialogs: Vec<DialogInfo>,
document: DialogInfoDocument,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called for every valid RFC 4235 dialog-package NOTIFY.
Source§fn on_dialog_state_changed<'life0, 'async_trait>(
&'life0 self,
subscription_id: CallId,
dialog: DialogInfo,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_dialog_state_changed<'life0, 'async_trait>(
&'life0 self,
subscription_id: CallId,
dialog: DialogInfo,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called for each parsed RFC 4235 dialog entry transition.
Source§fn on_notify_received<'life0, 'async_trait>(
&'life0 self,
request: IncomingRequest,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_notify_received<'life0, 'async_trait>(
&'life0 self,
request: IncomingRequest,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
SIP_API_DESIGN_2 Phase E — typed inbound NOTIFY hook. Carries
the full
IncomingRequest so applications can inspect every
header on the NOTIFY (Server, Allow-Events, custom routing
hints) in addition to the legacy pre-decoded fields. Default
impl is a no-op.Source§fn on_refer_received<'life0, 'async_trait>(
&'life0 self,
request: IncomingRequest,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_refer_received<'life0, 'async_trait>(
&'life0 self,
request: IncomingRequest,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
SIP_API_DESIGN_2 Phase E — typed inbound REFER hook. Apps drive
accept/reject via
req.accept_refer() / req.reject_refer(...)
inside this callback. Use for header-level access (Referred-By,
Replaces, Target-Dialog, custom X-*).Source§fn on_info_received<'life0, 'async_trait>(
&'life0 self,
request: IncomingRequest,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_info_received<'life0, 'async_trait>(
&'life0 self,
request: IncomingRequest,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
SIP_API_DESIGN_2 Phase E — typed inbound INFO hook. Today’s
stack drops INFO at the dialog layer; this hook surfaces it so
SIP-INFO DTMF (
application/dtmf-relay), fax flow control,
and other application-layer signalling can be observed.Source§fn on_message_received<'life0, 'async_trait>(
&'life0 self,
request: IncomingRequest,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_message_received<'life0, 'async_trait>(
&'life0 self,
request: IncomingRequest,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
SIP_API_DESIGN_2 Phase E — typed inbound MESSAGE hook (RFC 3428).
Source§fn on_options_received<'life0, 'async_trait>(
&'life0 self,
request: IncomingRequest,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_options_received<'life0, 'async_trait>(
&'life0 self,
request: IncomingRequest,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
SIP_API_DESIGN_2 Phase E — typed inbound OPTIONS hook
(RFC 3261 §11). Both in-dialog and out-of-dialog OPTIONS reach
here;
request.call_id discriminates.Source§fn on_update_received<'life0, 'async_trait>(
&'life0 self,
request: IncomingRequest,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_update_received<'life0, 'async_trait>(
&'life0 self,
request: IncomingRequest,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
SIP_API_DESIGN_2 Phase E — typed inbound UPDATE hook
(RFC 3311). Fires in addition to the legacy hold/resume state
transitions; subscribe here for Session-Expires / X-*
header inspection.
Source§fn on_register_received<'life0, 'async_trait>(
&'life0 self,
register: IncomingRegister,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_register_received<'life0, 'async_trait>(
&'life0 self,
register: IncomingRegister,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
SIP_API_DESIGN_2 Phase D — typed inbound REGISTER hook
(RFC 3261 §10). Registrar surfaces author the response via
register.accept_builder() / register.challenge_builder(..) /
register.reject_builder(status); if the handler returns
without authoring a response, the dialog stack falls back to
the auto-response path.Source§fn on_registration_success<'life0, 'async_trait>(
&'life0 self,
registrar: String,
expires: u32,
contact: String,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_registration_success<'life0, 'async_trait>(
&'life0 self,
registrar: String,
expires: u32,
contact: String,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when registration succeeds.
Source§fn on_registration_failed<'life0, 'async_trait>(
&'life0 self,
registrar: String,
status_code: u16,
reason: String,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_registration_failed<'life0, 'async_trait>(
&'life0 self,
registrar: String,
status_code: u16,
reason: String,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when registration fails.
Source§fn on_unregistration_success<'life0, 'async_trait>(
&'life0 self,
registrar: String,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_unregistration_success<'life0, 'async_trait>(
&'life0 self,
registrar: String,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when unregistration succeeds.
Source§fn on_unregistration_failed<'life0, 'async_trait>(
&'life0 self,
registrar: String,
reason: String,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_unregistration_failed<'life0, 'async_trait>(
&'life0 self,
registrar: String,
reason: String,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when unregistration fails.
Source§fn on_sip_trace<'life0, 'async_trait>(
&'life0 self,
trace: SipTrace,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_sip_trace<'life0, 'async_trait>(
&'life0 self,
trace: SipTrace,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called for each SIP trace event when tracing is enabled.
Source§fn on_auth_retrying<'life0, 'async_trait>(
&'life0 self,
call_id: CallId,
status_code: u16,
realm: String,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn on_auth_retrying<'life0, 'async_trait>(
&'life0 self,
call_id: CallId,
status_code: u16,
realm: String,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Called when an outgoing call receives a 401/407 and the coordinator is
about to retry with
Authorization / Proxy-Authorization (RFC 3261
§22.2). Informational — the retry proceeds automatically if credentials
are on file via Config.credentials or
coord.invite(...).with_credentials(...); this hook does not alter
flow. Useful for logging or surfacing auth activity in a UI.Auto Trait Implementations§
impl !RefUnwindSafe for ClosureHandler
impl !UnwindSafe for ClosureHandler
impl Freeze for ClosureHandler
impl Send for ClosureHandler
impl Sync for ClosureHandler
impl Unpin for ClosureHandler
impl UnsafeUnpin for ClosureHandler
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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> 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