pub enum Real {
Binary {
mantissa: f64,
base: u32,
exponent: i32,
enc_base: u8,
},
Infinity,
NegInfinity,
Zero,
}
Available on crate feature
mtls
only.Expand description
Variants§
Implementations§
§impl Real
impl Real
pub const fn with_enc_base(self, enc_base: u8) -> Real
pub fn is_infinite(&self) -> bool
pub fn is_infinite(&self) -> bool
Returns true
if this value is positive infinity or negative infinity, and
false
otherwise.
Trait Implementations§
§impl<'a> CheckDerConstraints for Real
impl<'a> CheckDerConstraints for Real
§impl ToDer for Real
impl ToDer for Real
§fn to_der_len(&self) -> Result<usize, Error>
fn to_der_len(&self) -> Result<usize, Error>
Get the length of the object, when encoded
§fn write_der_header(
&self,
writer: &mut dyn Write
) -> Result<usize, SerializeError>
fn write_der_header( &self, writer: &mut dyn Write ) -> Result<usize, SerializeError>
Attempt to write the DER header to this writer.
§fn write_der_content(
&self,
writer: &mut dyn Write
) -> Result<usize, SerializeError>
fn write_der_content( &self, writer: &mut dyn Write ) -> Result<usize, SerializeError>
Attempt to write the DER content (all except header) to this writer.
§fn to_der_vec(&self) -> Result<Vec<u8, Global>, SerializeError>
fn to_der_vec(&self) -> Result<Vec<u8, Global>, SerializeError>
Write the DER encoded representation to a newly allocated
Vec<u8>
.§fn to_der_vec_raw(&self) -> Result<Vec<u8, Global>, SerializeError>
fn to_der_vec_raw(&self) -> Result<Vec<u8, Global>, SerializeError>
Similar to using
to_vec
, but uses provided values without changes.
This can generate an invalid encoding for a DER object.§fn write_der(&self, writer: &mut dyn Write) -> Result<usize, SerializeError>
fn write_der(&self, writer: &mut dyn Write) -> Result<usize, SerializeError>
Attempt to write the DER encoded representation (header and content) into this writer. Read more
§fn write_der_raw(&self, writer: &mut dyn Write) -> Result<usize, SerializeError>
fn write_der_raw(&self, writer: &mut dyn Write) -> Result<usize, SerializeError>
Similar to using
to_der
, but uses provided values without changes.
This can generate an invalid encoding for a DER object.impl StructuralPartialEq for Real
Auto Trait Implementations§
impl RefUnwindSafe for Real
impl Send for Real
impl Sync for Real
impl Unpin for Real
impl UnwindSafe for Real
Blanket Implementations§
§impl<'a, T> AsTaggedExplicit<'a> for Twhere
T: 'a,
impl<'a, T> AsTaggedExplicit<'a> for Twhere T: 'a,
§impl<'a, T> AsTaggedImplicit<'a> for Twhere
T: 'a,
impl<'a, T> AsTaggedImplicit<'a> for Twhere T: 'a,
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
§impl<T> Choice for Twhere
T: Tagged,
impl<T> Choice for Twhere T: Tagged,
§fn can_decode(tag: Tag) -> bool
fn can_decode(tag: Tag) -> bool
Is the provided
Tag
decodable as a variant of this CHOICE
?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>
§impl<T> IntoCollection<T> for T
impl<T> IntoCollection<T> for T
§fn into_collection<A>(self) -> SmallVec<A>where
A: Array<Item = T>,
fn into_collection<A>(self) -> SmallVec<A>where A: Array<Item = T>,
Converts
self
into a collection.