Skip to main content

Source

Trait Source 

Source
pub trait Source<A>: Element {
    // Required method
    fn read(self) -> A;

    // Provided method
    fn borrowed(_items: &[Self]) -> Option<&[A]> { ... }
}
Expand description

An item that reads as type A: a Boolean as a number, an integer as a wider integer, a float or a complex number, a float as a float of another width or a complex number, and a complex number as one of the other width.

Required Methods§

Source

fn read(self) -> A

Provided Methods§

Source

fn borrowed(_items: &[Self]) -> Option<&[A]>

items as A with no copy, where the items already have type A.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl Source<Complex<f32>> for Complex64

Source§

impl Source<Complex<f32>> for bool

Source§

impl Source<Complex<f32>> for f16

Source§

impl Source<Complex<f32>> for f32

Source§

impl Source<Complex<f32>> for f64

Source§

impl Source<Complex<f32>> for i16

Source§

impl Source<Complex<f32>> for i32

Source§

impl Source<Complex<f32>> for i64

Source§

impl Source<Complex<f32>> for u8

Source§

impl Source<Complex<f64>> for Complex32

Source§

impl Source<Complex<f64>> for bool

Source§

impl Source<Complex<f64>> for f16

Source§

impl Source<Complex<f64>> for f32

Source§

impl Source<Complex<f64>> for f64

Source§

impl Source<Complex<f64>> for i16

Source§

impl Source<Complex<f64>> for i32

Source§

impl Source<Complex<f64>> for i64

Source§

impl Source<Complex<f64>> for u8

Source§

impl Source<f16> for bool

Source§

fn read(self) -> f16

Source§

impl Source<f16> for f32

Source§

fn read(self) -> f16

Source§

impl Source<f16> for f64

Source§

fn read(self) -> f16

Source§

impl Source<f16> for i16

Source§

fn read(self) -> f16

Source§

impl Source<f16> for i32

Source§

fn read(self) -> f16

Source§

impl Source<f16> for i64

Source§

fn read(self) -> f16

Source§

impl Source<f16> for u8

Source§

fn read(self) -> f16

Source§

impl Source<f32> for bool

Source§

fn read(self) -> f32

Source§

impl Source<f32> for f16

Source§

fn read(self) -> f32

Source§

impl Source<f32> for f64

Source§

fn read(self) -> f32

Source§

impl Source<f32> for i16

Source§

fn read(self) -> f32

Source§

impl Source<f32> for i32

Source§

fn read(self) -> f32

Source§

impl Source<f32> for i64

Source§

fn read(self) -> f32

Source§

impl Source<f32> for u8

Source§

fn read(self) -> f32

Source§

impl Source<f64> for bool

Source§

fn read(self) -> f64

Source§

impl Source<f64> for f16

Source§

fn read(self) -> f64

Source§

impl Source<f64> for f32

Source§

fn read(self) -> f64

Source§

impl Source<f64> for i16

Source§

fn read(self) -> f64

Source§

impl Source<f64> for i32

Source§

fn read(self) -> f64

Source§

impl Source<f64> for i64

Source§

fn read(self) -> f64

Source§

impl Source<f64> for u8

Source§

fn read(self) -> f64

Source§

impl Source<i16> for bool

Source§

fn read(self) -> i16

Source§

impl Source<i16> for u8

Source§

fn read(self) -> i16

Source§

impl Source<i32> for bool

Source§

fn read(self) -> i32

Source§

impl Source<i32> for i16

Source§

fn read(self) -> i32

Source§

impl Source<i32> for u8

Source§

fn read(self) -> i32

Source§

impl Source<i64> for bool

Source§

fn read(self) -> i64

Source§

impl Source<i64> for i16

Source§

fn read(self) -> i64

Source§

impl Source<i64> for i32

Source§

fn read(self) -> i64

Source§

impl Source<i64> for u8

Source§

fn read(self) -> i64

Source§

impl Source<u8> for bool

Source§

fn read(self) -> u8

Implementors§

Source§

impl<A: Element> Source<A> for A