[][src]Struct sequoia_openpgp::cert::components::ComponentAmalgamation

pub struct ComponentAmalgamation<'a, C> { /* fields omitted */ }

A certificate's component and its associated data.

Methods

impl<'a> ComponentAmalgamation<'a, UserID>[src]

pub fn userid(&self) -> &UserID[src]

Returns a reference to the User ID.

impl<'a> ComponentAmalgamation<'a, UserAttribute>[src]

pub fn user_attribute(&self) -> &UserAttribute[src]

Returns a reference to the User Attribute.

Methods from Deref<Target = ComponentBundle<C>>

pub fn component(&self) -> &C[src]

Returns a reference to the component.

pub fn binding_signature<T>(
    &self,
    policy: &dyn Policy,
    t: T
) -> Option<&Signature> where
    T: Into<Option<SystemTime>>, 
[src]

Returns the active binding signature at time t.

An active binding signature is a non-revoked, self-signature that is alive at time t (creation time <= t, t < expiry).

This function returns None if there are no active binding signatures at time t.

pub fn self_signatures(&self) -> &[Signature][src]

The self-signatures.

The signatures are validated, and they are reverse sorted by their creation time (newest first).

pub fn certifications(&self) -> &[Signature][src]

Any third-party certifications.

The signatures are not validated. They are reverse sorted by their creation time (newest first).

pub fn self_revocations(&self) -> &[Signature][src]

Revocations issued by the key itself.

The revocations are validated, and they are reverse sorted by their creation time (newest first).

pub fn other_revocations(&self) -> &[Signature][src]

Revocations issued by other keys.

The revocations are not validated. They are reverse sorted by their creation time (newest first).

pub fn key(&self) -> &Key<P, R>[src]

Returns a reference to the key.

pub fn revoked<T>(&self, policy: &dyn Policy, t: T) -> RevocationStatus where
    T: Into<Option<SystemTime>>, 
[src]

Returns the subkey's revocation status at time t.

A subkey is revoked at time t if:

  • There is a live revocation at time t that is newer than all live self signatures at time t, or

  • There is a hard revocation (even if it is not live at time t, and even if there is a newer self-signature).

Note: Certs and subkeys have different criteria from User IDs and User Attributes.

Note: this only returns whether this subkey is revoked; it does not imply anything about the Cert or other components.

pub fn userid(&self) -> &UserID[src]

Returns a reference to the User ID.

pub fn revoked<T>(&self, policy: &dyn Policy, t: T) -> RevocationStatus where
    T: Into<Option<SystemTime>>, 
[src]

Returns the User ID's revocation status at time t.

A User ID is revoked at time t if:

  • There is a live revocation at time t that is newer than all live self signatures at time t, or

Note: Certs and subkeys have different criteria from User IDs and User Attributes.

Note: this only returns whether this User ID is revoked; it does not imply anything about the Cert or other components.

pub fn user_attribute(&self) -> &UserAttribute[src]

Returns a reference to the User Attribute.

pub fn revoked<T>(&self, policy: &dyn Policy, t: T) -> RevocationStatus where
    T: Into<Option<SystemTime>>, 
[src]

Returns the User Attribute's revocation status at time t.

A User Attribute is revoked at time t if:

  • There is a live revocation at time t that is newer than all live self signatures at time t, or

Note: Certs and subkeys have different criteria from User IDs and User Attributes.

Note: this only returns whether this User Attribute is revoked; it does not imply anything about the Cert or other components.

pub fn unknown(&self) -> &Unknown[src]

Returns a reference to the unknown component.

Trait Implementations

impl<'a, C> Amalgamation<'a, C> for ComponentAmalgamation<'a, C>[src]

type V = ValidComponentAmalgamation<'a, C>

The type returned by with_policy.

impl<'a, C: Clone> Clone for ComponentAmalgamation<'a, C>[src]

fn clone_from(&mut self, source: &Self)
1.0.0
[src]

Performs copy-assignment from source. Read more

impl<'a, C> Deref for ComponentAmalgamation<'a, C>[src]

type Target = ComponentBundle<C>

The resulting type after dereferencing.

impl<'a, C: Debug> Debug for ComponentAmalgamation<'a, C>[src]

Auto Trait Implementations

impl<'a, C> Send for ComponentAmalgamation<'a, C> where
    C: Sync

impl<'a, C> Sync for ComponentAmalgamation<'a, C> where
    C: Sync

Blanket Implementations

impl<T> From for T[src]

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip for T where
    V: MultiLane<T>,