use crate::Time;
impl Time {
pub fn is_set(&self) -> bool {
*self != Self::default()
}
}
#[derive(Debug, Clone, Copy)]
pub enum Format {
Custom(CustomFormat),
Unix,
Raw,
}
#[derive(Clone, Copy, Debug)]
pub struct CustomFormat(pub(crate) &'static str);
impl CustomFormat {
pub const fn new(format: &'static str) -> Self {
Self(format)
}
}
impl From<CustomFormat> for Format {
fn from(custom_format: CustomFormat) -> Format {
Format::Custom(custom_format)
}
}
pub mod format;
mod init;
mod write;