Struct hdk::prelude::CounterSigningSessionData
source · [−]pub struct CounterSigningSessionData { /* private fields */ }
Expand description
All the data required for a countersigning session.
Implementations
pub fn try_from_responses(
responses: Vec<PreflightResponse, Global>
) -> Result<CounterSigningSessionData, CounterSigningError>
pub fn try_from_responses(
responses: Vec<PreflightResponse, Global>
) -> Result<CounterSigningSessionData, CounterSigningError>
Attempt to build session data from a vector of responses.
pub fn agent_state_for_agent(
&self,
agent: &HoloHash<Agent>
) -> Result<&CounterSigningAgentState, CounterSigningError>
pub fn agent_state_for_agent(
&self,
agent: &HoloHash<Agent>
) -> Result<&CounterSigningAgentState, CounterSigningError>
Get the agent state for a specific agent.
pub fn build_header_set(
&self,
entry_hash: HoloHash<Entry>
) -> Result<Vec<Header, Global>, CounterSigningError>
pub fn build_header_set(
&self,
entry_hash: HoloHash<Entry>
) -> Result<Vec<Header, Global>, CounterSigningError>
Attempt to map countersigning session data to a set of headers. A given countersigning session always maps to the same ordered set of headers or an error. Note the headers are not signed as the intent is to build headers for other agents without their private keys.
pub fn try_new(
preflight_request: PreflightRequest,
responses: Vec<(CounterSigningAgentState, Signature), Global>
) -> Result<CounterSigningSessionData, CounterSigningError>
pub fn try_new(
preflight_request: PreflightRequest,
responses: Vec<(CounterSigningAgentState, Signature), Global>
) -> Result<CounterSigningSessionData, CounterSigningError>
Fallible constructor.
Combines all integrity checks.
Check that the countersigning session data responses all have the correct indexes.
Construct a Timestamp from countersigning session data. Ostensibly used for the Header because the session itself covers a time range.
Accessor to the preflight request.
Get all the agents signing for this session.
Trait Implementations
pub fn deserialize<__D>(
__deserializer: __D
) -> Result<CounterSigningSessionData, <__D as Deserializer<'de>>::Error> where
__D: Deserializer<'de>,
pub fn deserialize<__D>(
__deserializer: __D
) -> Result<CounterSigningSessionData, <__D as Deserializer<'de>>::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
This method tests for !=
.
pub fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error> where
__S: Serializer,
pub fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error> where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations
impl RefUnwindSafe for CounterSigningSessionData
impl Send for CounterSigningSessionData
impl Sync for CounterSigningSessionData
impl Unpin for CounterSigningSessionData
impl UnwindSafe for CounterSigningSessionData
Blanket Implementations
Mutably borrows from an owned value. Read more
Compare self to key
and return true
if they are equal.
fn instrument(self, span: Span) -> Instrumented<Self>ⓘNotable traits for Instrumented<T>impl<T> Future for Instrumented<T> where
T: Future, type Output = <T as Future>::Output;
fn instrument(self, span: Span) -> Instrumented<Self>ⓘNotable traits for Instrumented<T>impl<T> Future for Instrumented<T> where
T: Future, type Output = <T as Future>::Output;
impl<T> Future for Instrumented<T> where
T: Future, type Output = <T as Future>::Output;
fn in_current_span(self) -> Instrumented<Self>ⓘNotable traits for Instrumented<T>impl<T> Future for Instrumented<T> where
T: Future, type Output = <T as Future>::Output;
fn in_current_span(self) -> Instrumented<Self>ⓘNotable traits for Instrumented<T>impl<T> Future for Instrumented<T> where
T: Future, type Output = <T as Future>::Output;
impl<T> Future for Instrumented<T> where
T: Future, type Output = <T as Future>::Output;
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>ⓘNotable traits for WithDispatch<T>impl<T> Future for WithDispatch<T> where
T: Future, type Output = <T as Future>::Output;
where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>ⓘNotable traits for WithDispatch<T>impl<T> Future for WithDispatch<T> where
T: Future, type Output = <T as Future>::Output;
where
S: Into<Dispatch>,
impl<T> Future for WithDispatch<T> where
T: Future, type Output = <T as Future>::Output;
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
fn with_current_subscriber(self) -> WithDispatch<Self>ⓘNotable traits for WithDispatch<T>impl<T> Future for WithDispatch<T> where
T: Future, type Output = <T as Future>::Output;
fn with_current_subscriber(self) -> WithDispatch<Self>ⓘNotable traits for WithDispatch<T>impl<T> Future for WithDispatch<T> where
T: Future, type Output = <T as Future>::Output;
impl<T> Future for WithDispatch<T> where
T: Future, type Output = <T as Future>::Output;
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more