Struct fhir_rs::datatype::primitive::DateTimeDt
source · pub struct DateTimeDt {
pub id: Option<String>,
pub extension: Option<Vec<Extension>>,
pub value: Option<DateTime>,
}
Expand description
日期与时间
时间部分如果存在,必须到秒,如果精度不足,可以使用00填充。 如果存在时间,则必须提供时区。如果不确定时区,可以使用Z表示当地时区。
精度不限,展示形式灵活。可以表示如下几种格式:
- 年 - 2023
- 年月 - 2023-08
- 年月日 - 2023-08-17
- 年月日时分秒 - 2023-08-17T08:21:45Z
- 年月日时分秒(毫秒) - 2023-08-17T08:21:45.234Z
- 年月日时分秒(毫秒)时区 - 2023-08-17T08:21:45.234+08:00
Fields§
§id: Option<String>
xml:id (or equivalent in JSON)
extension: Option<Vec<Extension>>
Additional content defined by implementations
value: Option<DateTime>
Primitive value for dateTime
Trait Implementations§
source§impl Clone for DateTimeDt
impl Clone for DateTimeDt
source§fn clone(&self) -> DateTimeDt
fn clone(&self) -> DateTimeDt
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for DateTimeDt
impl Debug for DateTimeDt
source§impl<'de> Deserialize<'de> for DateTimeDt
impl<'de> Deserialize<'de> for DateTimeDt
fn deserialize<De>(deserializer: De) -> Result<Self>where
De: Deserializer<'de>,
source§impl Display for DateTimeDt
impl Display for DateTimeDt
source§impl Element for DateTimeDt
impl Element for DateTimeDt
fn has_id(&self) -> bool
fn id(&self) -> &Option<String>
fn set_id<T: Into<String>>(self, id: T) -> Self
fn has_extension(&self) -> bool
fn extension(&self) -> &Option<Vec<Extension>>
fn set_extension(self, ext: Vec<Extension>) -> Self
fn add_extension(self, ext: Extension) -> Self
source§impl From<&str> for DateTimeDt
impl From<&str> for DateTimeDt
source§impl FromStr for DateTimeDt
impl FromStr for DateTimeDt
source§impl Primitive for DateTimeDt
impl Primitive for DateTimeDt
source§impl Serialize for DateTimeDt
impl Serialize for DateTimeDt
Auto Trait Implementations§
impl RefUnwindSafe for DateTimeDt
impl Send for DateTimeDt
impl Sync for DateTimeDt
impl Unpin for DateTimeDt
impl UnwindSafe for DateTimeDt
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