pub struct XsdDateTime { /* private fields */ }Expand description
A validated XSD DateTime wrapper that ensures type safety and correct formatting.
This type wraps oxsdatatypes::DateTime and provides a type-safe way to work
with XSD DateTime values (e.g., “2026-01-20T12:34:56Z”). The datetime string
is validated upon construction, ensuring it can be parsed into a proper DateTime.
Implementations§
Source§impl XsdDateTime
impl XsdDateTime
Sourcepub fn new(value: &str) -> Result<Self, XsdDateTimeParseError>
pub fn new(value: &str) -> Result<Self, XsdDateTimeParseError>
Creates a new XsdDateTime from a string slice.
§Errors
Returns XsdDateTimeParseError if the string cannot be parsed as a valid XSD DateTime.
Sourcepub fn into_inner(self) -> DateTime
pub fn into_inner(self) -> DateTime
Consumes self and returns the underlying DateTime value.
Trait Implementations§
Source§impl Clone for XsdDateTime
impl Clone for XsdDateTime
Source§fn clone(&self) -> XsdDateTime
fn clone(&self) -> XsdDateTime
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for XsdDateTime
impl Debug for XsdDateTime
Source§impl<'de> Deserialize<'de> for XsdDateTime
impl<'de> Deserialize<'de> for XsdDateTime
Source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Deserializes an XsdDateTime from a string.
The input is expected to be a string containing a valid XSD dateTime
lexical value. Any parsing error is converted into a serde
deserialization error via de::Error::custom.
Source§impl Display for XsdDateTime
impl Display for XsdDateTime
Source§impl Hash for XsdDateTime
impl Hash for XsdDateTime
Source§impl PartialEq for XsdDateTime
impl PartialEq for XsdDateTime
Source§impl PartialOrd for XsdDateTime
impl PartialOrd for XsdDateTime
Source§impl Serialize for XsdDateTime
impl Serialize for XsdDateTime
impl Eq for XsdDateTime
impl StructuralPartialEq for XsdDateTime
Auto Trait Implementations§
impl Freeze for XsdDateTime
impl RefUnwindSafe for XsdDateTime
impl Send for XsdDateTime
impl Sync for XsdDateTime
impl Unpin for XsdDateTime
impl UnsafeUnpin for XsdDateTime
impl UnwindSafe for XsdDateTime
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.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>
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
Source§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.