Trait nifti::object::NiftiObject
source · pub trait NiftiObject {
type Volume: NiftiVolume;
// Required methods
fn header(&self) -> &NiftiHeader;
fn header_mut(&mut self) -> &mut NiftiHeader;
fn extensions(&self) -> &ExtensionSequence;
fn volume(&self) -> &Self::Volume;
fn into_volume(self) -> Self::Volume;
}
Expand description
Trait type for all possible implementations of owning NIFTI-1 objects. Objects contain a NIFTI header, a volume, and a possibly empty extension sequence.
Required Associated Types§
sourcetype Volume: NiftiVolume
type Volume: NiftiVolume
The concrete type of the volume.
Required Methods§
sourcefn header(&self) -> &NiftiHeader
fn header(&self) -> &NiftiHeader
Obtain a reference to the NIFTI header.
sourcefn header_mut(&mut self) -> &mut NiftiHeader
fn header_mut(&mut self) -> &mut NiftiHeader
Obtain a mutable reference to the NIFTI header.
sourcefn extensions(&self) -> &ExtensionSequence
fn extensions(&self) -> &ExtensionSequence
Obtain a reference to the object’s extensions.
sourcefn into_volume(self) -> Self::Volume
fn into_volume(self) -> Self::Volume
Move the volume out of the object, discarding the header and extensions.