Struct pkcs8::Attributes
source · [−]pub struct Attributes<'a>(_);
Expand description
Attributes as defined in RFC 5958 Section 2.
attributes is OPTIONAL. It contains information corresponding to the public key (e.g., certificates). The attributes field uses the class
ATTRIBUTE
which is restricted by theOneAsymmetricKeyAttributes
information object set.OneAsymmetricKeyAttributes
is an open ended set in this document. Others documents can constrain these values. Attributes from RFC2985 MAY be supported.
Attributes have the following ASN.1 schema:
Attributes ::= SET OF Attribute { { OneAsymmetricKeyAttributes } }
Trait Implementations
sourceimpl<'a> Clone for Attributes<'a>
impl<'a> Clone for Attributes<'a>
sourcefn clone(&self) -> Attributes<'a>
fn clone(&self) -> Attributes<'a>
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl<'a> Debug for Attributes<'a>
impl<'a> Debug for Attributes<'a>
sourceimpl<'a> Encodable for Attributes<'a>
impl<'a> Encodable for Attributes<'a>
sourcefn encoded_len(&self) -> Result<Length>
fn encoded_len(&self) -> Result<Length>
Compute the length of this value in bytes when encoded as ASN.1 DER.
sourcefn encode(&self, encoder: &mut Encoder<'_>) -> Result<()>
fn encode(&self, encoder: &mut Encoder<'_>) -> Result<()>
Encode this value as ASN.1 DER using the provided Encoder
.
sourcefn encode_to_slice(&self, buf: &'a mut [u8]) -> Result<&'a [u8], Error>
fn encode_to_slice(&self, buf: &'a mut [u8]) -> Result<&'a [u8], Error>
Encode this value to the provided byte slice, returning a sub-slice containing the encoded message. Read more
sourceimpl<'a> From<Attributes<'a>> for Any<'a>
impl<'a> From<Attributes<'a>> for Any<'a>
sourcefn from(attrs: Attributes<'a>) -> Any<'a>
fn from(attrs: Attributes<'a>) -> Any<'a>
Converts to this type from the input type.
sourceimpl<'a> Ord for Attributes<'a>
impl<'a> Ord for Attributes<'a>
sourceimpl<'a> PartialEq<Attributes<'a>> for Attributes<'a>
impl<'a> PartialEq<Attributes<'a>> for Attributes<'a>
sourcefn eq(&self, other: &Attributes<'a>) -> bool
fn eq(&self, other: &Attributes<'a>) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &Attributes<'a>) -> bool
fn ne(&self, other: &Attributes<'a>) -> bool
This method tests for !=
.
sourceimpl<'a> PartialOrd<Attributes<'a>> for Attributes<'a>
impl<'a> PartialOrd<Attributes<'a>> for Attributes<'a>
sourcefn partial_cmp(&self, other: &Attributes<'a>) -> Option<Ordering>
fn partial_cmp(&self, other: &Attributes<'a>) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
1.0.0 · sourcefn lt(&self, other: &Rhs) -> bool
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
sourceimpl<'a> TryFrom<Any<'a>> for Attributes<'a>
impl<'a> TryFrom<Any<'a>> for Attributes<'a>
impl<'a> Copy for Attributes<'a>
impl<'a> Eq for Attributes<'a>
impl<'a> StructuralEq for Attributes<'a>
impl<'a> StructuralPartialEq for Attributes<'a>
Auto Trait Implementations
impl<'a> RefUnwindSafe for Attributes<'a>
impl<'a> Send for Attributes<'a>
impl<'a> Sync for Attributes<'a>
impl<'a> Unpin for Attributes<'a>
impl<'a> UnwindSafe for Attributes<'a>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more