DType

Trait DType 

Source
pub trait DType {
    // Required methods
    fn name(&self) -> &'static str;
    fn primitive_type(&self) -> PrimitiveType;
    fn size(&self) -> usize;
    fn alignment(&self) -> usize;
    fn as_any(&self) -> &dyn Any;
    fn boxed_dtype(&self) -> Box<dyn DType>;
}

Required Methods§

Source

fn name(&self) -> &'static str

Source

fn primitive_type(&self) -> PrimitiveType

Source

fn size(&self) -> usize

Source

fn alignment(&self) -> usize

Source

fn as_any(&self) -> &dyn Any

Source

fn boxed_dtype(&self) -> Box<dyn DType>

Trait Implementations§

Source§

impl Clone for Box<dyn DType>

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl TryFrom<PrimitiveType> for Box<dyn DType>

Source§

type Error = Error

The type returned in the event of a conversion error.
Source§

fn try_from(value: PrimitiveType) -> Result<Self>

Performs the conversion.

Implementors§

Source§

impl<T: Type> DType for T