pub struct SignedObject<O: SignableObject> { /* private fields */ }Implementations§
Source§impl<O> SignedObject<O>
impl<O> SignedObject<O>
pub fn inner(&self) -> &O
pub fn unwrap(self) -> O
pub fn signer(&self) -> &Verifier
pub fn from_keypair(keypair: &DidKeyPair, inner: O) -> Result<Self, Error>
pub fn from_key(key: &SecretKey, inner: O) -> Result<Self, Error>
pub fn new(signer: Signer, inner: O) -> Result<Self, Error>
pub fn verify_with_key(self, key: &PublicKey) -> Result<O, Error>
pub async fn verify( &self, did_resolver: &dyn DidResolver, verifier: Option<&Verifier>, ) -> Result<Verifier, Error>
Trait Implementations§
Source§impl<O: Clone + SignableObject> Clone for SignedObject<O>
impl<O: Clone + SignableObject> Clone for SignedObject<O>
Source§fn clone(&self) -> SignedObject<O>
fn clone(&self) -> SignedObject<O>
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<O: Debug + SignableObject> Debug for SignedObject<O>
impl<O: Debug + SignableObject> Debug for SignedObject<O>
Source§impl<'de, O> Deserialize<'de> for SignedObject<O>where
O: Deserialize<'de> + SignableObject,
impl<'de, O> Deserialize<'de> for SignedObject<O>where
O: Deserialize<'de> + SignableObject,
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<O> Hashable for SignedObject<O>
impl<O> Hashable for SignedObject<O>
Source§impl<O> Indexable for SignedObject<O>
impl<O> Indexable for SignedObject<O>
const PRIMARY_KEY: &'static str = O::PRIMARY_KEY
const DEFAULT_SORT: &'static str = O::DEFAULT_SORT
fn primary_key(&self) -> Vec<u8> ⓘ
fn secondary_keys(&self) -> Index
Source§impl<O: Ord + SignableObject> Ord for SignedObject<O>
impl<O: Ord + SignableObject> Ord for SignedObject<O>
Source§fn cmp(&self, other: &SignedObject<O>) -> Ordering
fn cmp(&self, other: &SignedObject<O>) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl<O: PartialEq + SignableObject> PartialEq for SignedObject<O>
impl<O: PartialEq + SignableObject> PartialEq for SignedObject<O>
Source§impl<O: PartialOrd + SignableObject> PartialOrd for SignedObject<O>
impl<O: PartialOrd + SignableObject> PartialOrd for SignedObject<O>
Source§impl<O> Serialize for SignedObject<O>where
O: Serialize + SignableObject,
impl<O> Serialize for SignedObject<O>where
O: Serialize + SignableObject,
impl<O: Eq + SignableObject> Eq for SignedObject<O>
impl<O: SignableObject> StructuralPartialEq for SignedObject<O>
Auto Trait Implementations§
impl<O> Freeze for SignedObject<O>where
O: Freeze,
impl<O> RefUnwindSafe for SignedObject<O>where
O: RefUnwindSafe,
impl<O> Send for SignedObject<O>where
O: Send,
impl<O> Sync for SignedObject<O>where
O: Sync,
impl<O> Unpin for SignedObject<O>where
O: Unpin,
impl<O> UnwindSafe for SignedObject<O>where
O: UnwindSafe,
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,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit)Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§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