Trait npyz::TypeWrite[][src]

pub trait TypeWrite {
    type Value: ?Sized;
    fn write_one<W: Write>(&self, writer: W, value: &Self::Value) -> Result<()>
    where
        Self: Sized
; }
Expand description

Like some sort of for<W: io::Write> Fn(W, &T) -> io::Result<()>.

For an example of how to implement this manually, see Vector5 in the roundtrip test.

Trait objects

dyn TypeWrite has no object-safe methods. If you need dynamic polymorphism, use dyn TypeWriteDyn instead.

Associated Types

Type accepted by the function.

Required methods

The function.

Implementations on Foreign Types

Implementors