pub struct Gateway { /* private fields */ }Expand description
One bounded direct-first gateway resolution.
Implementations§
Source§impl Gateway
impl Gateway
Sourcepub fn new(
policy: PolicySnapshot,
limits: GatewayLimits,
) -> Result<Gateway, GatewayError>
pub fn new( policy: PolicySnapshot, limits: GatewayLimits, ) -> Result<Gateway, GatewayError>
Create from the exact current persistent policy.
Sourcepub const fn plan(&self) -> &TransportPlan
pub const fn plan(&self) -> &TransportPlan
Exact direct-first typed plan.
Sourcepub fn next_attempt(
&mut self,
current_policy: PolicySnapshot,
now: u64,
) -> Result<GatewayAttempt, GatewayError>
pub fn next_attempt( &mut self, current_policy: PolicySnapshot, now: u64, ) -> Result<GatewayAttempt, GatewayError>
Begin the next policy-selected candidate.
Sourcepub fn complete(
&mut self,
current_policy: PolicySnapshot,
attempt: GatewayAttempt,
outcome: AttemptOutcome,
now: u64,
) -> Result<GatewayStep, GatewayError>
pub fn complete( &mut self, current_policy: PolicySnapshot, attempt: GatewayAttempt, outcome: AttemptOutcome, now: u64, ) -> Result<GatewayStep, GatewayError>
Complete the exact active attempt.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Gateway
impl RefUnwindSafe for Gateway
impl Send for Gateway
impl Sync for Gateway
impl Unpin for Gateway
impl UnsafeUnpin for Gateway
impl UnwindSafe for Gateway
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