Type Alias sequoia_openpgp::cert::amalgamation::key::ErasedKeyAmalgamation
source · pub type ErasedKeyAmalgamation<'a, P> = KeyAmalgamation<'a, P, UnspecifiedRole, bool>;
Expand description
An amalgamation whose role is not known at compile time.
A specialized version of KeyAmalgamation
.
Unlike a Key
or a KeyBundle
with an unspecified role, an
ErasedKeyAmalgamation
remembers its role; it is just not exposed
to the type system. For details, see the module-level
documentation.
Aliased Type§
struct ErasedKeyAmalgamation<'a, P> { /* private fields */ }
Implementations§
source§impl<'a, P> ErasedKeyAmalgamation<'a, P>where
P: KeyParts,
impl<'a, P> ErasedKeyAmalgamation<'a, P>where
P: KeyParts,
sourcepub fn parts_into_public(self) -> ErasedKeyAmalgamation<'a, PublicParts>
pub fn parts_into_public(self) -> ErasedKeyAmalgamation<'a, PublicParts>
Changes the key’s parts tag to PublicParts
.
sourcepub fn parts_as_public(&'a self) -> &'a ErasedKeyAmalgamation<'a, PublicParts>
pub fn parts_as_public(&'a self) -> &'a ErasedKeyAmalgamation<'a, PublicParts>
Changes the key’s parts tag to PublicParts
.
sourcepub fn parts_as_public_mut(
&'a mut self,
) -> &'a mut ErasedKeyAmalgamation<'a, PublicParts>
pub fn parts_as_public_mut( &'a mut self, ) -> &'a mut ErasedKeyAmalgamation<'a, PublicParts>
Changes the key’s parts tag to PublicParts
.
sourcepub fn parts_into_secret(self) -> Result<ErasedKeyAmalgamation<'a, SecretParts>>
pub fn parts_into_secret(self) -> Result<ErasedKeyAmalgamation<'a, SecretParts>>
Changes the key’s parts tag to SecretParts
.
sourcepub fn parts_as_secret(
&'a self,
) -> Result<&'a ErasedKeyAmalgamation<'a, SecretParts>>
pub fn parts_as_secret( &'a self, ) -> Result<&'a ErasedKeyAmalgamation<'a, SecretParts>>
Changes the key’s parts tag to SecretParts
.
sourcepub fn parts_as_secret_mut(
&'a mut self,
) -> Result<&'a mut ErasedKeyAmalgamation<'a, SecretParts>>
pub fn parts_as_secret_mut( &'a mut self, ) -> Result<&'a mut ErasedKeyAmalgamation<'a, SecretParts>>
Changes the key’s parts tag to SecretParts
.
sourcepub fn parts_into_unspecified(
self,
) -> ErasedKeyAmalgamation<'a, UnspecifiedParts>
pub fn parts_into_unspecified( self, ) -> ErasedKeyAmalgamation<'a, UnspecifiedParts>
Changes the key’s parts tag to UnspecifiedParts
.
sourcepub fn parts_as_unspecified(
&'a self,
) -> &ErasedKeyAmalgamation<'a, UnspecifiedParts>
pub fn parts_as_unspecified( &'a self, ) -> &ErasedKeyAmalgamation<'a, UnspecifiedParts>
Changes the key’s parts tag to UnspecifiedParts
.
sourcepub fn parts_as_unspecified_mut(
&'a mut self,
) -> &mut ErasedKeyAmalgamation<'a, UnspecifiedParts>
pub fn parts_as_unspecified_mut( &'a mut self, ) -> &mut ErasedKeyAmalgamation<'a, UnspecifiedParts>
Changes the key’s parts tag to UnspecifiedParts
.
Trait Implementations§
source§impl<'a> From<&'a KeyAmalgamation<'a, PublicParts, UnspecifiedRole, bool>> for &'a ErasedKeyAmalgamation<'a, UnspecifiedParts>
impl<'a> From<&'a KeyAmalgamation<'a, PublicParts, UnspecifiedRole, bool>> for &'a ErasedKeyAmalgamation<'a, UnspecifiedParts>
source§fn from(p: &'a ErasedKeyAmalgamation<'a, PublicParts>) -> Self
fn from(p: &'a ErasedKeyAmalgamation<'a, PublicParts>) -> Self
Converts to this type from the input type.
source§impl<'a> From<&'a KeyAmalgamation<'a, SecretParts, UnspecifiedRole, bool>> for &'a ErasedKeyAmalgamation<'a, PublicParts>
impl<'a> From<&'a KeyAmalgamation<'a, SecretParts, UnspecifiedRole, bool>> for &'a ErasedKeyAmalgamation<'a, PublicParts>
source§fn from(p: &'a ErasedKeyAmalgamation<'a, SecretParts>) -> Self
fn from(p: &'a ErasedKeyAmalgamation<'a, SecretParts>) -> Self
Converts to this type from the input type.
source§impl<'a> From<&'a KeyAmalgamation<'a, SecretParts, UnspecifiedRole, bool>> for &'a ErasedKeyAmalgamation<'a, UnspecifiedParts>
impl<'a> From<&'a KeyAmalgamation<'a, SecretParts, UnspecifiedRole, bool>> for &'a ErasedKeyAmalgamation<'a, UnspecifiedParts>
source§fn from(p: &'a ErasedKeyAmalgamation<'a, SecretParts>) -> Self
fn from(p: &'a ErasedKeyAmalgamation<'a, SecretParts>) -> Self
Converts to this type from the input type.
source§impl<'a> From<&'a KeyAmalgamation<'a, UnspecifiedParts, UnspecifiedRole, bool>> for &'a ErasedKeyAmalgamation<'a, PublicParts>
impl<'a> From<&'a KeyAmalgamation<'a, UnspecifiedParts, UnspecifiedRole, bool>> for &'a ErasedKeyAmalgamation<'a, PublicParts>
source§fn from(p: &'a ErasedKeyAmalgamation<'a, UnspecifiedParts>) -> Self
fn from(p: &'a ErasedKeyAmalgamation<'a, UnspecifiedParts>) -> Self
Converts to this type from the input type.
source§impl<'a> From<&'a mut KeyAmalgamation<'a, PublicParts, UnspecifiedRole, bool>> for &'a mut ErasedKeyAmalgamation<'a, UnspecifiedParts>
impl<'a> From<&'a mut KeyAmalgamation<'a, PublicParts, UnspecifiedRole, bool>> for &'a mut ErasedKeyAmalgamation<'a, UnspecifiedParts>
source§fn from(p: &'a mut ErasedKeyAmalgamation<'a, PublicParts>) -> Self
fn from(p: &'a mut ErasedKeyAmalgamation<'a, PublicParts>) -> Self
Converts to this type from the input type.
source§impl<'a> From<&'a mut KeyAmalgamation<'a, SecretParts, UnspecifiedRole, bool>> for &'a mut ErasedKeyAmalgamation<'a, PublicParts>
impl<'a> From<&'a mut KeyAmalgamation<'a, SecretParts, UnspecifiedRole, bool>> for &'a mut ErasedKeyAmalgamation<'a, PublicParts>
source§fn from(p: &'a mut ErasedKeyAmalgamation<'a, SecretParts>) -> Self
fn from(p: &'a mut ErasedKeyAmalgamation<'a, SecretParts>) -> Self
Converts to this type from the input type.
source§impl<'a> From<&'a mut KeyAmalgamation<'a, SecretParts, UnspecifiedRole, bool>> for &'a mut ErasedKeyAmalgamation<'a, UnspecifiedParts>
impl<'a> From<&'a mut KeyAmalgamation<'a, SecretParts, UnspecifiedRole, bool>> for &'a mut ErasedKeyAmalgamation<'a, UnspecifiedParts>
source§fn from(p: &'a mut ErasedKeyAmalgamation<'a, SecretParts>) -> Self
fn from(p: &'a mut ErasedKeyAmalgamation<'a, SecretParts>) -> Self
Converts to this type from the input type.
source§impl<'a> From<&'a mut KeyAmalgamation<'a, UnspecifiedParts, UnspecifiedRole, bool>> for &'a mut ErasedKeyAmalgamation<'a, PublicParts>
impl<'a> From<&'a mut KeyAmalgamation<'a, UnspecifiedParts, UnspecifiedRole, bool>> for &'a mut ErasedKeyAmalgamation<'a, PublicParts>
source§fn from(p: &'a mut ErasedKeyAmalgamation<'a, UnspecifiedParts>) -> Self
fn from(p: &'a mut ErasedKeyAmalgamation<'a, UnspecifiedParts>) -> Self
Converts to this type from the input type.
source§impl<'a, P: 'a + KeyParts> From<KeyAmalgamation<'a, P, PrimaryRole, ()>> for ErasedKeyAmalgamation<'a, P>
impl<'a, P: 'a + KeyParts> From<KeyAmalgamation<'a, P, PrimaryRole, ()>> for ErasedKeyAmalgamation<'a, P>
source§fn from(ka: PrimaryKeyAmalgamation<'a, P>) -> Self
fn from(ka: PrimaryKeyAmalgamation<'a, P>) -> Self
Converts to this type from the input type.
source§impl<'a, P: 'a + KeyParts> From<KeyAmalgamation<'a, P, SubordinateRole, ()>> for ErasedKeyAmalgamation<'a, P>
impl<'a, P: 'a + KeyParts> From<KeyAmalgamation<'a, P, SubordinateRole, ()>> for ErasedKeyAmalgamation<'a, P>
source§fn from(ka: SubordinateKeyAmalgamation<'a, P>) -> Self
fn from(ka: SubordinateKeyAmalgamation<'a, P>) -> Self
Converts to this type from the input type.
source§impl<'a> From<KeyAmalgamation<'a, PublicParts, PrimaryRole, ()>> for ErasedKeyAmalgamation<'a, UnspecifiedParts>
impl<'a> From<KeyAmalgamation<'a, PublicParts, PrimaryRole, ()>> for ErasedKeyAmalgamation<'a, UnspecifiedParts>
source§fn from(ka: PrimaryKeyAmalgamation<'a, PublicParts>) -> Self
fn from(ka: PrimaryKeyAmalgamation<'a, PublicParts>) -> Self
Converts to this type from the input type.
source§impl<'a> From<KeyAmalgamation<'a, PublicParts, SubordinateRole, ()>> for ErasedKeyAmalgamation<'a, UnspecifiedParts>
impl<'a> From<KeyAmalgamation<'a, PublicParts, SubordinateRole, ()>> for ErasedKeyAmalgamation<'a, UnspecifiedParts>
source§fn from(ka: SubordinateKeyAmalgamation<'a, PublicParts>) -> Self
fn from(ka: SubordinateKeyAmalgamation<'a, PublicParts>) -> Self
Converts to this type from the input type.
source§impl<'a> From<KeyAmalgamation<'a, PublicParts, UnspecifiedRole, bool>> for ErasedKeyAmalgamation<'a, UnspecifiedParts>
impl<'a> From<KeyAmalgamation<'a, PublicParts, UnspecifiedRole, bool>> for ErasedKeyAmalgamation<'a, UnspecifiedParts>
source§fn from(p: ErasedKeyAmalgamation<'a, PublicParts>) -> Self
fn from(p: ErasedKeyAmalgamation<'a, PublicParts>) -> Self
Converts to this type from the input type.
source§impl<'a> From<KeyAmalgamation<'a, SecretParts, PrimaryRole, ()>> for ErasedKeyAmalgamation<'a, PublicParts>
impl<'a> From<KeyAmalgamation<'a, SecretParts, PrimaryRole, ()>> for ErasedKeyAmalgamation<'a, PublicParts>
source§fn from(ka: PrimaryKeyAmalgamation<'a, SecretParts>) -> Self
fn from(ka: PrimaryKeyAmalgamation<'a, SecretParts>) -> Self
Converts to this type from the input type.
source§impl<'a> From<KeyAmalgamation<'a, SecretParts, PrimaryRole, ()>> for ErasedKeyAmalgamation<'a, UnspecifiedParts>
impl<'a> From<KeyAmalgamation<'a, SecretParts, PrimaryRole, ()>> for ErasedKeyAmalgamation<'a, UnspecifiedParts>
source§fn from(ka: PrimaryKeyAmalgamation<'a, SecretParts>) -> Self
fn from(ka: PrimaryKeyAmalgamation<'a, SecretParts>) -> Self
Converts to this type from the input type.
source§impl<'a> From<KeyAmalgamation<'a, SecretParts, SubordinateRole, ()>> for ErasedKeyAmalgamation<'a, PublicParts>
impl<'a> From<KeyAmalgamation<'a, SecretParts, SubordinateRole, ()>> for ErasedKeyAmalgamation<'a, PublicParts>
source§fn from(ka: SubordinateKeyAmalgamation<'a, SecretParts>) -> Self
fn from(ka: SubordinateKeyAmalgamation<'a, SecretParts>) -> Self
Converts to this type from the input type.
source§impl<'a> From<KeyAmalgamation<'a, SecretParts, SubordinateRole, ()>> for ErasedKeyAmalgamation<'a, UnspecifiedParts>
impl<'a> From<KeyAmalgamation<'a, SecretParts, SubordinateRole, ()>> for ErasedKeyAmalgamation<'a, UnspecifiedParts>
source§fn from(ka: SubordinateKeyAmalgamation<'a, SecretParts>) -> Self
fn from(ka: SubordinateKeyAmalgamation<'a, SecretParts>) -> Self
Converts to this type from the input type.
source§impl<'a> From<KeyAmalgamation<'a, SecretParts, UnspecifiedRole, bool>> for ErasedKeyAmalgamation<'a, PublicParts>
impl<'a> From<KeyAmalgamation<'a, SecretParts, UnspecifiedRole, bool>> for ErasedKeyAmalgamation<'a, PublicParts>
source§fn from(p: ErasedKeyAmalgamation<'a, SecretParts>) -> Self
fn from(p: ErasedKeyAmalgamation<'a, SecretParts>) -> Self
Converts to this type from the input type.
source§impl<'a> From<KeyAmalgamation<'a, SecretParts, UnspecifiedRole, bool>> for ErasedKeyAmalgamation<'a, UnspecifiedParts>
impl<'a> From<KeyAmalgamation<'a, SecretParts, UnspecifiedRole, bool>> for ErasedKeyAmalgamation<'a, UnspecifiedParts>
source§fn from(p: ErasedKeyAmalgamation<'a, SecretParts>) -> Self
fn from(p: ErasedKeyAmalgamation<'a, SecretParts>) -> Self
Converts to this type from the input type.
source§impl<'a> From<KeyAmalgamation<'a, UnspecifiedParts, PrimaryRole, ()>> for ErasedKeyAmalgamation<'a, PublicParts>
impl<'a> From<KeyAmalgamation<'a, UnspecifiedParts, PrimaryRole, ()>> for ErasedKeyAmalgamation<'a, PublicParts>
source§fn from(ka: PrimaryKeyAmalgamation<'a, UnspecifiedParts>) -> Self
fn from(ka: PrimaryKeyAmalgamation<'a, UnspecifiedParts>) -> Self
Converts to this type from the input type.
source§impl<'a> From<KeyAmalgamation<'a, UnspecifiedParts, SubordinateRole, ()>> for ErasedKeyAmalgamation<'a, PublicParts>
impl<'a> From<KeyAmalgamation<'a, UnspecifiedParts, SubordinateRole, ()>> for ErasedKeyAmalgamation<'a, PublicParts>
source§fn from(ka: SubordinateKeyAmalgamation<'a, UnspecifiedParts>) -> Self
fn from(ka: SubordinateKeyAmalgamation<'a, UnspecifiedParts>) -> Self
Converts to this type from the input type.
source§impl<'a> From<KeyAmalgamation<'a, UnspecifiedParts, UnspecifiedRole, bool>> for ErasedKeyAmalgamation<'a, PublicParts>
impl<'a> From<KeyAmalgamation<'a, UnspecifiedParts, UnspecifiedRole, bool>> for ErasedKeyAmalgamation<'a, PublicParts>
source§fn from(p: ErasedKeyAmalgamation<'a, UnspecifiedParts>) -> Self
fn from(p: ErasedKeyAmalgamation<'a, UnspecifiedParts>) -> Self
Converts to this type from the input type.
source§impl<'a, P> PrimaryKey<'a, P, UnspecifiedRole> for ErasedKeyAmalgamation<'a, P>where
P: 'a + KeyParts,
impl<'a, P> PrimaryKey<'a, P, UnspecifiedRole> for ErasedKeyAmalgamation<'a, P>where
P: 'a + KeyParts,
source§impl<'a> TryFrom<&'a KeyAmalgamation<'a, PublicParts, UnspecifiedRole, bool>> for &'a ErasedKeyAmalgamation<'a, SecretParts>
impl<'a> TryFrom<&'a KeyAmalgamation<'a, PublicParts, UnspecifiedRole, bool>> for &'a ErasedKeyAmalgamation<'a, SecretParts>
source§fn try_from(p: &'a ErasedKeyAmalgamation<'a, PublicParts>) -> Result<Self>
fn try_from(p: &'a ErasedKeyAmalgamation<'a, PublicParts>) -> Result<Self>
Performs the conversion.
source§impl<'a> TryFrom<&'a KeyAmalgamation<'a, UnspecifiedParts, UnspecifiedRole, bool>> for &'a ErasedKeyAmalgamation<'a, SecretParts>
impl<'a> TryFrom<&'a KeyAmalgamation<'a, UnspecifiedParts, UnspecifiedRole, bool>> for &'a ErasedKeyAmalgamation<'a, SecretParts>
source§fn try_from(p: &'a ErasedKeyAmalgamation<'a, UnspecifiedParts>) -> Result<Self>
fn try_from(p: &'a ErasedKeyAmalgamation<'a, UnspecifiedParts>) -> Result<Self>
Performs the conversion.
source§impl<'a> TryFrom<&'a mut KeyAmalgamation<'a, PublicParts, UnspecifiedRole, bool>> for &'a mut ErasedKeyAmalgamation<'a, SecretParts>
impl<'a> TryFrom<&'a mut KeyAmalgamation<'a, PublicParts, UnspecifiedRole, bool>> for &'a mut ErasedKeyAmalgamation<'a, SecretParts>
source§fn try_from(p: &'a mut ErasedKeyAmalgamation<'a, PublicParts>) -> Result<Self>
fn try_from(p: &'a mut ErasedKeyAmalgamation<'a, PublicParts>) -> Result<Self>
Performs the conversion.
source§impl<'a> TryFrom<&'a mut KeyAmalgamation<'a, UnspecifiedParts, UnspecifiedRole, bool>> for &'a mut ErasedKeyAmalgamation<'a, SecretParts>
impl<'a> TryFrom<&'a mut KeyAmalgamation<'a, UnspecifiedParts, UnspecifiedRole, bool>> for &'a mut ErasedKeyAmalgamation<'a, SecretParts>
source§fn try_from(
p: &'a mut ErasedKeyAmalgamation<'a, UnspecifiedParts>,
) -> Result<Self>
fn try_from( p: &'a mut ErasedKeyAmalgamation<'a, UnspecifiedParts>, ) -> Result<Self>
Performs the conversion.
source§impl<'a> TryFrom<KeyAmalgamation<'a, PublicParts, UnspecifiedRole, bool>> for ErasedKeyAmalgamation<'a, SecretParts>
impl<'a> TryFrom<KeyAmalgamation<'a, PublicParts, UnspecifiedRole, bool>> for ErasedKeyAmalgamation<'a, SecretParts>
source§fn try_from(p: ErasedKeyAmalgamation<'a, PublicParts>) -> Result<Self>
fn try_from(p: ErasedKeyAmalgamation<'a, PublicParts>) -> Result<Self>
Performs the conversion.
source§impl<'a> TryFrom<KeyAmalgamation<'a, UnspecifiedParts, UnspecifiedRole, bool>> for ErasedKeyAmalgamation<'a, SecretParts>
impl<'a> TryFrom<KeyAmalgamation<'a, UnspecifiedParts, UnspecifiedRole, bool>> for ErasedKeyAmalgamation<'a, SecretParts>
source§fn try_from(p: ErasedKeyAmalgamation<'a, UnspecifiedParts>) -> Result<Self>
fn try_from(p: ErasedKeyAmalgamation<'a, UnspecifiedParts>) -> Result<Self>
Performs the conversion.
source§impl<'a, P> ValidateAmalgamation<'a, Key<P, UnspecifiedRole>> for ErasedKeyAmalgamation<'a, P>where
P: 'a + KeyParts,
impl<'a, P> ValidateAmalgamation<'a, Key<P, UnspecifiedRole>> for ErasedKeyAmalgamation<'a, P>where
P: 'a + KeyParts,
§type V = ValidKeyAmalgamation<'a, P, UnspecifiedRole, bool>
type V = ValidKeyAmalgamation<'a, P, UnspecifiedRole, bool>
The type returned by
with_policy
. Read more