pub struct Signed {
pub(crate) contextualized: Contextualized,
pub(crate) signatures: ServerSignatures,
}Expand description
State representing a signed event with event ID and signatures.
A signed event has been cryptographically signed and has a computed event ID based on the reference hash of the canonical JSON representation.
Fields§
§contextualized: ContextualizedThe contextualized event data
signatures: ServerSignaturesThe signatures
Implementations§
Source§impl Signed
impl Signed
Sourcepub fn build_event_value(&self) -> Value
pub fn build_event_value(&self) -> Value
Build the event JSON, similar to the one for a Contextualized event, but with the event_id, signatures, and hashes
Sourcepub fn build_event_object(&self) -> Result<CanonicalJsonObject, SigningError>
pub fn build_event_object(&self) -> Result<CanonicalJsonObject, SigningError>
Build the event object, similar to the one for a Contextualized event, but with the event_id, signatures, and hashes
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Signed
impl<'de> Deserialize<'de> for Signed
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for Signed
impl RefUnwindSafe for Signed
impl Send for Signed
impl Sync for Signed
impl Unpin for Signed
impl UnsafeUnpin for Signed
impl UnwindSafe for Signed
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