Struct holochain_integrity_types::record::SignedHashed
source · pub struct SignedHashed<T>where
T: HashableContent,{
pub hashed: HoloHashed<T>,
pub signature: Signature,
}
Expand description
Any content that has been hashed and signed.
Fields§
§hashed: HoloHashed<T>
The hashed content.
signature: Signature
The signature of the content.
Implementations§
source§impl<T> SignedHashed<T>where
T: HashableContent,
impl<T> SignedHashed<T>where
T: HashableContent,
sourcepub fn into_inner(self) -> (HoloHashed<T>, Signature)
pub fn into_inner(self) -> (HoloHashed<T>, Signature)
Destructure into a HoloHashed
and Signature
.
sourcepub fn as_hash(&self) -> &HoloHashOf<T>
pub fn as_hash(&self) -> &HoloHashOf<T>
Access the already-calculated hash stored in this wrapper type.
sourcepub fn with_presigned(hashed: HoloHashed<T>, signature: Signature) -> Self
pub fn with_presigned(hashed: HoloHashed<T>, signature: Signature) -> Self
Create with an existing signature.
source§impl SignedHashed<Action>
impl SignedHashed<Action>
sourcepub fn action_address(&self) -> &ActionHash
pub fn action_address(&self) -> &ActionHash
Access the Action Hash.
sourcepub fn raw_from_same_hash<T>(other: SignedHashed<T>) -> Self
pub fn raw_from_same_hash<T>(other: SignedHashed<T>) -> Self
Create a new SignedActionHashed from a type that implements into Action
and
has the same hash bytes.
The caller must make sure the hash does not change.
Trait Implementations§
source§impl AsRef<SignedHashed<Action>> for RegisterAgentActivity
impl AsRef<SignedHashed<Action>> for RegisterAgentActivity
source§fn as_ref(&self) -> &SignedActionHashed
fn as_ref(&self) -> &SignedActionHashed
Converts this type into a shared reference of the (usually inferred) input type.
source§impl AsRef<SignedHashed<Action>> for SignedActionHashed
impl AsRef<SignedHashed<Action>> for SignedActionHashed
source§fn as_ref(&self) -> &SignedActionHashed
fn as_ref(&self) -> &SignedActionHashed
Converts this type into a shared reference of the (usually inferred) input type.
source§impl<T> Clone for SignedHashed<T>where
T: HashableContent + Clone,
impl<T> Clone for SignedHashed<T>where
T: HashableContent + Clone,
source§fn clone(&self) -> SignedHashed<T>
fn clone(&self) -> SignedHashed<T>
Returns a copy 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<T> Debug for SignedHashed<T>where
T: HashableContent + Debug,
impl<T> Debug for SignedHashed<T>where
T: HashableContent + Debug,
source§impl<'de, T> Deserialize<'de> for SignedHashed<T>where
T: HashableContent + Deserialize<'de>,
impl<'de, T> Deserialize<'de> for SignedHashed<T>where
T: HashableContent + Deserialize<'de>,
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
source§impl From<SignedHashed<Action>> for Action
impl From<SignedHashed<Action>> for Action
source§fn from(signed_action_hashed: SignedActionHashed) -> Action
fn from(signed_action_hashed: SignedActionHashed) -> Action
Converts to this type from the input type.
source§impl<T> From<SignedHashed<T>> for HoloHashed<T>where
T: HashableContent,
impl<T> From<SignedHashed<T>> for HoloHashed<T>where
T: HashableContent,
source§fn from(sh: SignedHashed<T>) -> HoloHashed<T>
fn from(sh: SignedHashed<T>) -> HoloHashed<T>
Converts to this type from the input type.
source§impl<T> Hash for SignedHashed<T>where
T: HashableContent,
impl<T> Hash for SignedHashed<T>where
T: HashableContent,
source§impl<T> PartialEq for SignedHashed<T>where
T: HashableContent,
impl<T> PartialEq for SignedHashed<T>where
T: HashableContent,
source§impl<T> Serialize for SignedHashed<T>where
T: HashableContent + Serialize,
impl<T> Serialize for SignedHashed<T>where
T: HashableContent + Serialize,
impl<T> Eq for SignedHashed<T>where
T: HashableContent + Eq,
Auto Trait Implementations§
impl<T> RefUnwindSafe for SignedHashed<T>
impl<T> Send for SignedHashed<T>
impl<T> Sync for SignedHashed<T>
impl<T> Unpin for SignedHashed<T>
impl<T> UnwindSafe for SignedHashed<T>
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
§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
Checks if this value is equivalent to the given key. Read more
§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.