Skip to main content

DetachedCredentialRecovery

Struct DetachedCredentialRecovery 

Source
pub struct DetachedCredentialRecovery { /* private fields */ }
Expand description

Detached fenced credential-recovery witness.

This state is produced only by the exact binding fate of a marker-backed cursor witness; callers cannot fabricate a durable delivery fact.

Implementations§

Source§

impl DetachedCredentialRecovery

Source

pub const fn resulting_floor(self) -> DeliverySeq

Returns the floor measured by the binding fate that selected this recovery.

Source

pub fn storage_description( self, terminal: RestoredBindingFateTerminal, ) -> Result<StoredEdgeRestore, RestoredBindingFateTerminal>

Describes this recovery as the capsule that restores it, given the terminal of the binding fate that selected it.

The terminal is not stored on the edge – the crate’s size lint refuses it, at 43 errors for 88 bytes – so it is resolved from the member the recovery belongs to and handed in here. That is sound because a standing detached edge refuses ordinary detached attach (ClosureState::ordinary_detached_attach_admission), so the member cannot have committed a later terminal while this edge stands.

Every other field is the edge’s own, including the whole marker-progress predecessor: the restore requires the progress’s cursor to equal its marker sequence and its nested delivery to agree field for field, so the predecessor states nothing this edge does not already know.

§Errors

Returns the terminal unchanged unless it names this recovery’s own participant, prior epoch and conversation – the exact check the restore makes before it will accept the capsule, made here so a description that could not be restored is never written.

Source

pub const fn conversation_id(self) -> ConversationId

Returns the conversation inherited from the marker-backed cursor witness.

Source

pub const fn participant_id(self) -> ParticipantId

Returns the detached participant.

Source

pub const fn marker_delivery_seq(self) -> DeliverySeq

Returns the delivered recovery marker.

Source

pub const fn prior_binding_epoch(self) -> BindingEpoch

Returns the prior authoritative epoch.

Source§

impl DetachedCredentialRecovery

Source

pub const fn validate_leave_claim( &self, participant_id: ParticipantId, actual_charge: ResourceVector, remaining_k: ResourceVector, exit_claims: u64, ) -> Option<KClaimBackedDetachedLeave>

Validates exact-current K and exit claims for detached Leave.

Source

pub fn detached_leave( self, debt: ClosureDebt, event: Event, evidence: KClaimBackedDetachedLeave, successor: DebtCompletion, ) -> Result<ClosureState, ClosureState>

Consumes exact K-backed detached Leave and installs only clear/OP/PC.

§Errors

Returns the unchanged owed state unless the Leave and private claim authority are bound to this exact recovery edge.

Source

pub const fn ordinary_attach_refusal(self) -> DetachedAttachRefusal

Ordinary non-fenced attach is refused without mutation.

Source

pub const fn marker_attach_refusal( self, presented_marker: DeliverySeq, ) -> Option<DetachedAttachRefusal>

An explicit marker is eligible only when it is the exact recovery marker.

Source

pub const fn authority_superseded(self) -> (Self, DetachedAttachRefusal)

Authority supersession before commit preserves DCR and is stale.

Source

pub const fn unrelated_event( self, debt: ClosureDebt, event: Event, resulting_debt: Option<ClosureDebt>, ) -> Result<ClosureState, ClosureState>

Applies only an unrelated participant event, preserving this edge while debt remains or clearing it with debt.

§Errors

Returns the unchanged owed state for a non-participant event or an event owned by this detached participant.

Trait Implementations§

Source§

impl Clone for DetachedCredentialRecovery

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Copy for DetachedCredentialRecovery

Source§

impl Debug for DetachedCredentialRecovery

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Eq for DetachedCredentialRecovery

Source§

impl PartialEq for DetachedCredentialRecovery

Source§

fn eq(&self, other: &Self) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl StructuralPartialEq for DetachedCredentialRecovery

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.