pub enum Time {
UtcTime(UtcTime),
GeneralTime(GeneralizedTime),
}Expand description
X.501 Time as defined in RFC 5280 Section 4.1.2.5.
Schema definition from RFC 5280 Appendix A:
Time ::= CHOICE {
utcTime UTCTime,
generalTime GeneralizedTime
}Variants§
UtcTime(UtcTime)
Legacy UTC time (has 2-digit year, valid from 1970 to 2049).
Note: RFC 5280 specifies 1950-2049, however due to common operations working on
UNIX_EPOCH this implementation’s lower bound is 1970.
GeneralTime(GeneralizedTime)
Modern GeneralizedTime encoding with 4-digit year.
Implementations§
Trait Implementations§
impl Copy for Time
Source§impl EncodeValue for Time
impl EncodeValue for Time
impl Eq for Time
Source§impl From<GeneralizedTime> for Time
impl From<GeneralizedTime> for Time
Source§fn from(time: GeneralizedTime) -> Time
fn from(time: GeneralizedTime) -> Time
Converts to this type from the input type.
impl StructuralPartialEq for Time
Auto Trait Implementations§
impl Forget for Time
impl Freeze for Time
impl Move for Time
impl RefUnwindSafe for Time
impl Send for Time
impl Sync for Time
impl Unpin for Time
impl UnsafeUnpin for Time
impl UnwindSafe for Time
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