pub struct CommitHeader { /* private fields */ }Expand description
Public authenticated metadata for an encrypted commit body.
Implementations§
Source§impl CommitHeader
impl CommitHeader
Sourcepub fn new(
domain_id: DomainId,
epoch: u64,
author: AuthorId,
author_sequence: u64,
dependencies: Vec<CommitId>,
capability_id: CapabilityId,
schema_ids: Vec<SchemaId>,
nonce: [u8; 24],
) -> Result<CommitHeader, CommitCodecError>
pub fn new( domain_id: DomainId, epoch: u64, author: AuthorId, author_sequence: u64, dependencies: Vec<CommitId>, capability_id: CapabilityId, schema_ids: Vec<SchemaId>, nonce: [u8; 24], ) -> Result<CommitHeader, CommitCodecError>
Validates and constructs a canonical commit header.
Returns the authenticated endpoint author.
Returns the author’s contiguous domain-local sequence.
Sourcepub fn dependencies(&self) -> &[CommitId]
pub fn dependencies(&self) -> &[CommitId]
Returns the sorted, unique causal frontier dependencies.
Sourcepub const fn capability_id(&self) -> CapabilityId
pub const fn capability_id(&self) -> CapabilityId
Returns the capability authorizing the transaction.
Sourcepub fn schema_ids(&self) -> &[SchemaId]
pub fn schema_ids(&self) -> &[SchemaId]
Returns the sorted, unique schemas used by operations.
Trait Implementations§
Source§impl Clone for CommitHeader
impl Clone for CommitHeader
Source§fn clone(&self) -> CommitHeader
fn clone(&self) -> CommitHeader
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for CommitHeader
impl Debug for CommitHeader
Source§impl PartialEq for CommitHeader
impl PartialEq for CommitHeader
impl Eq for CommitHeader
impl StructuralPartialEq for CommitHeader
Auto Trait Implementations§
impl Freeze for CommitHeader
impl RefUnwindSafe for CommitHeader
impl Send for CommitHeader
impl Sync for CommitHeader
impl Unpin for CommitHeader
impl UnwindSafe for CommitHeader
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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