[][src]Struct dicom_core::header::DataElement

pub struct DataElement<I> { /* fields omitted */ }

A data type that represents and owns a DICOM data element. Unlike PrimitiveDataElement, this type may contain multiple data elements through the item sequence VR (of type I).

Methods

impl<I> DataElement<I> where
    I: DicomValueType
[src]

pub fn empty(tag: Tag, vr: VR) -> Self[src]

Create an empty data element.

pub fn new(tag: Tag, vr: VR, value: Value<I>) -> Self[src]

Create a primitive data element from the given parts. This method will not check whether the value representation is compatible with the given value.

pub fn header(&self) -> &DataElementHeader[src]

Retrieve the element header.

pub fn value(&self) -> &Value<I>[src]

Retrieve the data value.

pub fn vr(&self) -> VR[src]

Retrieve the value representation, which may be unknown or not applicable.

pub fn to_str(&self) -> Result<Cow<str>>[src]

Retrieve the element's value as a single string.

Trait Implementations

impl<I> Header for DataElement<I>[src]

fn is_item(&self) -> bool[src]

Check whether this is the header of an item.

fn is_item_delimiter(&self) -> bool[src]

Check whether this is the header of an item delimiter.

fn is_sequence_delimiter(&self) -> bool[src]

Check whether this is the header of a sequence delimiter.

impl<'a, I> Header for &'a DataElement<I>[src]

fn is_item(&self) -> bool[src]

Check whether this is the header of an item.

fn is_item_delimiter(&self) -> bool[src]

Check whether this is the header of an item delimiter.

fn is_sequence_delimiter(&self) -> bool[src]

Check whether this is the header of a sequence delimiter.

impl<I> From<PrimitiveDataElement> for DataElement<I>[src]

impl<I: PartialEq> PartialEq<DataElement<I>> for DataElement<I>[src]

impl<I: Clone> Clone for DataElement<I>[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl<I: Debug> Debug for DataElement<I>[src]

Auto Trait Implementations

impl<I> Send for DataElement<I> where
    I: Send

impl<I> Unpin for DataElement<I> where
    I: Unpin

impl<I> Sync for DataElement<I> where
    I: Sync

impl<I> UnwindSafe for DataElement<I> where
    I: RefUnwindSafe + UnwindSafe

impl<I> RefUnwindSafe for DataElement<I> where
    I: RefUnwindSafe

Blanket Implementations

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]