Trait dicom_core::header::HasLength[][src]

pub trait HasLength {
    fn length(&self) -> Length;

    fn is_empty(&self) -> bool { ... }
}
Expand description

Trait for any DICOM entity (element or item) which may have a length.

Required methods

Retrieve the value data’s length as specified by the data element or item, in bytes.

It is named length to make it distinct from the conventional method signature len(&self) -> usize for the number of elements of a collection.

According to the standard, the concrete value size may be undefined, which can be the case for sequence elements or specific primitive values.

Provided methods

Check whether the value is empty (0 length).

Implementors