FitsNumeric

Trait FitsNumeric 

Source
pub trait FitsNumeric: Default + Clone {
    // Required methods
    fn read_fits<R: Read>(
        reader: &mut R,
        datatype: FitsDataType,
    ) -> Result<Self>;
    fn write_fits<W: Write>(
        &self,
        writer: &mut W,
        datatype: FitsDataType,
    ) -> Result<()>;
}
Expand description

Trait for numeric types supported by FITS

Required Methods§

Source

fn read_fits<R: Read>(reader: &mut R, datatype: FitsDataType) -> Result<Self>

Source

fn write_fits<W: Write>( &self, writer: &mut W, datatype: FitsDataType, ) -> Result<()>

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl FitsNumeric for f32

Source§

fn read_fits<R: Read>(reader: &mut R, datatype: FitsDataType) -> Result<Self>

Source§

fn write_fits<W: Write>( &self, writer: &mut W, datatype: FitsDataType, ) -> Result<()>

Source§

impl FitsNumeric for f64

Source§

fn read_fits<R: Read>(reader: &mut R, datatype: FitsDataType) -> Result<Self>

Source§

fn write_fits<W: Write>( &self, writer: &mut W, datatype: FitsDataType, ) -> Result<()>

Implementors§