pub struct Any { /* private fields */ }Expand description
ASN.1 ANY: represents any explicitly tagged ASN.1 value.
This type provides the same functionality as AnyRef but owns the
backing data.
Implementations§
Source§impl Any
impl Any
Sourcepub fn decode_as<'a, T>(&'a self) -> Result<T, <T as DecodeValue<'a>>::Error>where
T: Choice<'a> + DecodeValue<'a>,
pub fn decode_as<'a, T>(&'a self) -> Result<T, <T as DecodeValue<'a>>::Error>where
T: Choice<'a> + DecodeValue<'a>,
Sourcepub fn decode_as_encoding<'a, T>(
&'a self,
encoding: EncodingRules,
) -> Result<T, <T as DecodeValue<'a>>::Error>where
T: Choice<'a> + DecodeValue<'a>,
pub fn decode_as_encoding<'a, T>(
&'a self,
encoding: EncodingRules,
) -> Result<T, <T as DecodeValue<'a>>::Error>where
T: Choice<'a> + DecodeValue<'a>,
Sourcepub fn encode_from<T>(msg: &T) -> Result<Self, Error>where
T: Tagged + EncodeValue,
pub fn encode_from<T>(msg: &T) -> Result<Self, Error>where
T: Tagged + EncodeValue,
Trait Implementations§
Source§impl<'a> Decode<'a> for Any
impl<'a> Decode<'a> for Any
Source§impl<'a> DecodeValue<'a> for Any
impl<'a> DecodeValue<'a> for Any
Source§impl EncodeValue for Any
impl EncodeValue for Any
Source§impl From<&BitStringRef<'_>> for Any
impl From<&BitStringRef<'_>> for Any
Source§fn from(bit_string_ref: &BitStringRef<'_>) -> Any
fn from(bit_string_ref: &BitStringRef<'_>) -> Any
Converts to this type from the input type.
Source§impl From<BitStringRef<'_>> for Any
impl From<BitStringRef<'_>> for Any
Source§fn from(bit_string_ref: BitStringRef<'_>) -> Any
fn from(bit_string_ref: BitStringRef<'_>) -> Any
Converts to this type from the input type.
Source§impl Ord for Any
impl Ord for Any
1.21.0 (const: unstable) · 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 OwnedToRef for Any
impl OwnedToRef for Any
Source§impl PartialOrd for Any
impl PartialOrd for Any
Source§impl<'__der: 'a, 'a> TryFrom<&'__der Any> for &'a OctetStringRef
Available on crate feature alloc only.
impl<'__der: 'a, 'a> TryFrom<&'__der Any> for &'a OctetStringRef
Available on crate feature
alloc only.Source§impl<'__der: 'a, 'a> TryFrom<&'__der Any> for BitStringRef<'a>
Available on crate feature alloc only.
impl<'__der: 'a, 'a> TryFrom<&'__der Any> for BitStringRef<'a>
Available on crate feature
alloc only.Source§impl<'__der> TryFrom<&'__der Any> for GeneralizedTime
Available on crate feature alloc only.
impl<'__der> TryFrom<&'__der Any> for GeneralizedTime
Available on crate feature
alloc only.Source§impl<'__der: 'a, 'a> TryFrom<&'__der Any> for Ia5StringRef<'a>
Available on crate feature alloc only.
impl<'__der: 'a, 'a> TryFrom<&'__der Any> for Ia5StringRef<'a>
Available on crate feature
alloc only.Source§impl<'__der: 'a, 'a> TryFrom<&'__der Any> for IntRef<'a>
Available on crate feature alloc only.
impl<'__der: 'a, 'a> TryFrom<&'__der Any> for IntRef<'a>
Available on crate feature
alloc only.Source§impl<'__der> TryFrom<&'__der Any> for OctetString
Available on crate feature alloc only.
impl<'__der> TryFrom<&'__der Any> for OctetString
Available on crate feature
alloc only.Source§impl<'__der> TryFrom<&'__der Any> for PrintableString
Available on crate feature alloc only.
impl<'__der> TryFrom<&'__der Any> for PrintableString
Available on crate feature
alloc only.Source§impl<'__der: 'a, 'a> TryFrom<&'__der Any> for PrintableStringRef<'a>
Available on crate feature alloc only.
impl<'__der: 'a, 'a> TryFrom<&'__der Any> for PrintableStringRef<'a>
Available on crate feature
alloc only.Source§impl<'__der> TryFrom<&'__der Any> for TeletexString
Available on crate feature alloc only.
impl<'__der> TryFrom<&'__der Any> for TeletexString
Available on crate feature
alloc only.Source§impl<'__der: 'a, 'a> TryFrom<&'__der Any> for TeletexStringRef<'a>
Available on crate feature alloc only.
impl<'__der: 'a, 'a> TryFrom<&'__der Any> for TeletexStringRef<'a>
Available on crate feature
alloc only.Source§impl<'__der: 'a, 'a> TryFrom<&'__der Any> for UintRef<'a>
Available on crate feature alloc only.
impl<'__der: 'a, 'a> TryFrom<&'__der Any> for UintRef<'a>
Available on crate feature
alloc only.Source§impl<'__der: 'a, 'a> TryFrom<&'__der Any> for Utf8StringRef<'a>
Available on crate feature alloc only.
impl<'__der: 'a, 'a> TryFrom<&'__der Any> for Utf8StringRef<'a>
Available on crate feature
alloc only.Source§impl<'__der: 'a, 'a> TryFrom<&'__der Any> for VideotexStringRef<'a>
Available on crate feature alloc only.
impl<'__der: 'a, 'a> TryFrom<&'__der Any> for VideotexStringRef<'a>
Available on crate feature
alloc only.impl Eq for Any
impl StructuralPartialEq for Any
Auto Trait Implementations§
impl Freeze for Any
impl RefUnwindSafe for Any
impl Send for Any
impl Sync for Any
impl Unpin for Any
impl UnsafeUnpin for Any
impl UnwindSafe for Any
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§impl<T> Encode for T
impl<T> Encode for T
Source§fn encoded_len(&self) -> Result<Length, Error>
fn encoded_len(&self) -> Result<Length, Error>
Compute the length of this TLV object in bytes when encoded as ASN.1 DER. Read more
Source§fn encode_to_slice<'a>(&self, buf: &'a mut [u8]) -> Result<&'a [u8]>
fn encode_to_slice<'a>(&self, buf: &'a mut [u8]) -> Result<&'a [u8]>
Encode this TLV object to the provided byte slice, returning a sub-slice
containing the encoded message. Read more