pub enum ValueFormat<T: Element + ?Sized> {
Scalar(Scalar<T>),
Spectrum(Spectrum<T>),
Image(Image<T>),
}Expand description
A data in any of the formats Tango has, as many dimensions as it has.
Variants§
Implementations§
Source§impl<T: Element + ?Sized> ValueFormat<T>
impl<T: Element + ?Sized> ValueFormat<T>
Sourcepub fn into_scalar(self) -> Result<Scalar<T>, Self>
pub fn into_scalar(self) -> Result<Scalar<T>, Self>
The data, if it is a scalar, or this format back.
Sourcepub fn into_spectrum(self) -> Result<Spectrum<T>, Self>
pub fn into_spectrum(self) -> Result<Spectrum<T>, Self>
The data, if it is a spectrum, or this format back.
Sourcepub fn into_image(self) -> Result<Image<T>, Self>
pub fn into_image(self) -> Result<Image<T>, Self>
The data, if it is a image, or this format back.
Trait Implementations§
Auto Trait Implementations§
impl<T> Forget for ValueFormat<T>where
T: ?Sized,
impl<T> Freeze for ValueFormat<T>
impl<T> RefUnwindSafe for ValueFormat<T>
impl<T> Send for ValueFormat<T>
impl<T> Sync for ValueFormat<T>
impl<T> Unpin for ValueFormat<T>
impl<T> UnsafeUnpin for ValueFormat<T>
impl<T> UnwindSafe for ValueFormat<T>
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