pub struct ClaimFrontiers { /* private fields */ }Expand description
Validated participant-keyed sequence and order claim authority.
Implementations§
Source§impl ClaimFrontiers
impl ClaimFrontiers
Sourcepub fn from_initial_enrollment<F>(
operation: InitialEnrollmentOperationCommit<F>,
attached_charge: ResourceVector,
) -> Result<InitialEnrollmentFrontierCommit<F>, Box<InitialEnrollmentFrontierFailure<F>>>
pub fn from_initial_enrollment<F>( operation: InitialEnrollmentOperationCommit<F>, attached_charge: ResourceVector, ) -> Result<InitialEnrollmentFrontierCommit<F>, Box<InitialEnrollmentFrontierFailure<F>>>
Constructs the complete initial frontier directly from one admitted
enrollment operation and its exact encoded Attached charge.
No restore representation, row list, claim list, or numeric position is
accepted from the caller. Participant zero, the retained lifecycle row,
A/X, T/E, and L x T owners are derived solely from the opaque
operation commit after its closure projection and aggregate ledgers are
cross-checked.
§Errors
Returns InitialEnrollmentFrontierError when the supplied charge or
any typed operation/projection invariant disagrees with the canonical
initial frontier.
Sourcepub fn restore(
restore: ClaimFrontiersRestore,
sequence_ledger: SequenceLedger,
order_ledger: OrderLedger,
) -> Result<Self, ParticipantStateCorruptReason>
pub fn restore( restore: ClaimFrontiersRestore, sequence_ledger: SequenceLedger, order_ledger: OrderLedger, ) -> Result<Self, ParticipantStateCorruptReason>
Restores exact frontiers only when their numeric unions, logical owners, product descriptors, DCR intervals, candidate keys, and aggregate ledgers all agree.
This standalone form accepts no compacted causal-history rows or binding origins. Snapshots containing either must use the protocol-owned event replay path so participant-owned history is restored first.
§Errors
Returns the deterministic first delivery-sequence fault before checking transaction order, then checks cross-counter candidate and DCR identity.
Sourcepub const fn active_identities(&self) -> &ActiveIdentityRanks
pub const fn active_identities(&self) -> &ActiveIdentityRanks
Borrows sorted current live identities.
Sourcepub const fn identity_slot_limit(&self) -> u64
pub const fn identity_slot_limit(&self) -> u64
Returns the signed permanent identity-slot capacity validated at restore.
Sourcepub const fn conversation_id(&self) -> ConversationId
pub const fn conversation_id(&self) -> ConversationId
Returns the owning conversation.
Sourcepub const fn retained_floor(&self) -> u128
pub const fn retained_floor(&self) -> u128
Returns the current physical retained suffix floor.
Sourcepub fn retained_records(&self) -> &[RetainedCausalRecord]
pub fn retained_records(&self) -> &[RetainedCausalRecord]
Borrows every validated physical row in the retained sequence suffix.
Sourcepub fn retained_marker_records(&self) -> &[RetainedCausalRecord]
pub fn retained_marker_records(&self) -> &[RetainedCausalRecord]
Borrows only the O(I) retained marker anchors needed by executable edges.
Sourcepub fn project_offered_marker_progress(
&self,
participant_id: ParticipantId,
binding_epoch: BindingEpoch,
marker_delivery_seq: DeliverySeq,
event: Event,
) -> Option<ParticipantCursorProgress>
pub fn project_offered_marker_progress( &self, participant_id: ParticipantId, binding_epoch: BindingEpoch, marker_delivery_seq: DeliverySeq, event: Event, ) -> Option<ParticipantCursorProgress>
Projects exact offered-marker cursor progress from one validated retained marker and its current bound identity.
Raw participant, epoch, and sequence inputs grant no authority: all must
match the coupled frontier’s retained marker anchor and active binding.
The returned progress is derived only through sealed MarkerDelivery
authority and the exact delivered event.
Sourcepub const fn sequence(&self) -> &SequenceClaimFrontier
pub const fn sequence(&self) -> &SequenceClaimFrontier
Borrows the validated sequence frontier.
Sourcepub const fn order(&self) -> &OrderClaimFrontier
pub const fn order(&self) -> &OrderClaimFrontier
Borrows the validated transaction-order frontier.
Sourcepub fn project_ordinary_record(
self,
input: OrdinaryRecordProjectionInput,
) -> Result<OrdinaryRecordProjectionDecision, Box<OrdinaryRecordProjectionFailure>>
pub fn project_ordinary_record( self, input: OrdinaryRecordProjectionInput, ) -> Result<OrdinaryRecordProjectionDecision, Box<OrdinaryRecordProjectionFailure>>
Consumes one complete validated frontier into the ordinary record fixed point, preventing storage callers from supplying disconnected retained rows, participant cursors, immutable candidates, or aggregate ledgers.
Exact keyed row charges remain durability facts. They are joined to the owned rows here before any floor/capacity/counter transition executes. The returned decision owns either the unchanged prestate and its exact earlier candidate, or the complete projected poststate.
§Errors
Returns OrdinaryRecordProjectionFailure for a conversation/binding
mismatch, malformed keyed charges/accounting, capacity or observer
refusal, counter exhaustion, or an impossible exact-owner relocation.
Every failure owns the unchanged frontier and original projection input.
Sourcepub fn planned_settled_leave_admission_order<F>(
&self,
member: &LiveMember<F>,
binding_state: BindingState,
) -> Result<AdmissionOrder, PrepareLeaveAuthorityError>
pub fn planned_settled_leave_admission_order<F>( &self, member: &LiveMember<F>, binding_state: BindingState, ) -> Result<AdmissionOrder, PrepareLeaveAuthorityError>
Returns the exact causal key a settled bound/detached Leave would consume without relinquishing frontier authority.
This planning view exists so a durable binding can compute the
canonical keyed Left row charge before calling the consuming commit.
The consuming preparation reruns the same validation.
§Errors
Returns PrepareLeaveAuthorityError under the same preconditions as
Self::prepare_settled_leave_authority.
Consumes the exact settled bound/detached X authority and relays the
surviving order lane behind the selected Left major.
Bound Leave also invalidates the same participant’s exact A handle.
Every immutable candidate must already have drained. The returned
authority owns this frontier snapshot and is intentionally non-cloneable;
only super::commit_leave can consume it.
§Errors
Returns PrepareLeaveAuthorityError when identity/binding authority,
candidate precedence, a logical handle, or checked relay capacity fails.
Sourcepub fn planned_pending_leave_admission_order<F>(
&self,
member: &LiveMember<F>,
pending: PendingFinalization,
) -> Result<AdmissionOrder, PrepareLeaveAuthorityError>
pub fn planned_pending_leave_admission_order<F>( &self, member: &LiveMember<F>, pending: PendingFinalization, ) -> Result<AdmissionOrder, PrepareLeaveAuthorityError>
Returns the exact causal key a pending-terminal Leave would consume after its immutable terminal, without relinquishing frontier authority.
§Errors
Returns PrepareLeaveAuthorityError under the same preconditions as
Self::prepare_pending_leave_authority.
Consumes the exact pending-terminal plus X positional order authority.
The pending terminal must be the sole immutable candidate, must match the
detached identity’s exact prior epoch, and must lie strictly before the
participant’s X handle. The returned non-cloneable authority owns the
relayed frontier snapshot and can be consumed only by
super::commit_pending_leave.
§Errors
Returns PrepareLeaveAuthorityError for mismatched identity/binding,
any unrelated candidate, absent logical ownership, or insufficient
checked suffix for the later-handle relocation.