Function dicom_core::value::deserialize::parse_datetime
source · pub fn parse_datetime(
buf: &[u8],
dt_utc_offset: FixedOffset
) -> Result<DateTime<FixedOffset>, Error>Expand description
Retrieve a chrono::DateTime from the given text, while assuming the given UTC offset.
- If a date/time component is missing, the operation fails.
- Presence of the second fraction component
.FFFFFFis mandatory with at least one digit accuracy.Fwhile missing digits default to zero. - For DateTime with missing components, or if exact second fraction accuracy needs to be preserved,
use
parse_datetime_partial.