Skip to main content

FromWire

Trait FromWire 

Source
pub trait FromWire: Sized {
    // Required method
    fn read_wire(reader: &mut WireReader, index: i32) -> Result<Self, WireError>;

    // Provided method
    fn read_result_payload(
        reader: &mut WireReader,
        index: Option<i32>,
    ) -> Result<Self, WireError> { ... }
}
Expand description

Decode a concrete value, consuming every visited wire node exactly once.

Required Methods§

Source

fn read_wire(reader: &mut WireReader, index: i32) -> Result<Self, WireError>

Provided Methods§

Source

fn read_result_payload( reader: &mut WireReader, index: Option<i32>, ) -> Result<Self, WireError>

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 FromWire for ()

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<(), WireError>

Source§

fn read_result_payload( _reader: &mut WireReader, index: Option<i32>, ) -> Result<(), WireError>

Source§

impl FromWire for DateTime<Utc>

Source§

fn read_wire( reader: &mut WireReader, index: i32, ) -> Result<DateTime<Utc>, WireError>

Source§

impl FromWire for Duration

Source§

impl FromWire for PathBuf

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<PathBuf, WireError>

Source§

impl FromWire for String

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<String, WireError>

Source§

impl FromWire for bool

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<bool, WireError>

Source§

impl FromWire for char

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<char, WireError>

Source§

impl FromWire for f32

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<f32, WireError>

Source§

impl FromWire for f64

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<f64, WireError>

Source§

impl FromWire for i8

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<i8, WireError>

Source§

impl FromWire for i16

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<i16, WireError>

Source§

impl FromWire for i32

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<i32, WireError>

Source§

impl FromWire for i64

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<i64, WireError>

Source§

impl FromWire for u8

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<u8, WireError>

Source§

impl FromWire for u16

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<u16, WireError>

Source§

impl FromWire for u32

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<u32, WireError>

Source§

impl FromWire for u64

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<u64, WireError>

Source§

impl FromWire for usize

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<usize, WireError>

Source§

impl<A, B, C, D, E, F, G, H> FromWire for (A, B, C, D, E, F, G, H)
where A: FromWire, B: FromWire, C: FromWire, D: FromWire, E: FromWire, F: FromWire, G: FromWire, H: FromWire,

Source§

impl<A, B, C, D, E, F, G> FromWire for (A, B, C, D, E, F, G)
where A: FromWire, B: FromWire, C: FromWire, D: FromWire, E: FromWire, F: FromWire, G: FromWire,

Source§

impl<A, B, C, D, E, F> FromWire for (A, B, C, D, E, F)
where A: FromWire, B: FromWire, C: FromWire, D: FromWire, E: FromWire, F: FromWire,

Source§

impl<A, B, C, D, E> FromWire for (A, B, C, D, E)
where A: FromWire, B: FromWire, C: FromWire, D: FromWire, E: FromWire,

Source§

impl<A, B, C, D> FromWire for (A, B, C, D)
where A: FromWire, B: FromWire, C: FromWire, D: FromWire,

Source§

fn read_wire( reader: &mut WireReader, index: i32, ) -> Result<(A, B, C, D), WireError>

Source§

impl<A, B, C> FromWire for (A, B, C)
where A: FromWire, B: FromWire, C: FromWire,

Source§

fn read_wire( reader: &mut WireReader, index: i32, ) -> Result<(A, B, C), WireError>

Source§

impl<A, B> FromWire for (A, B)
where A: FromWire, B: FromWire,

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<(A, B), WireError>

Source§

impl<A> FromWire for (A,)
where A: FromWire,

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<(A,), WireError>

Source§

impl<K, V> FromWire for BTreeMap<K, V>
where K: FromWire + Ord, V: FromWire,

Source§

fn read_wire( reader: &mut WireReader, index: i32, ) -> Result<BTreeMap<K, V>, WireError>

Source§

impl<K, V> FromWire for HashMap<K, V>
where K: FromWire + Eq + Hash, V: FromWire,

Source§

fn read_wire( reader: &mut WireReader, index: i32, ) -> Result<HashMap<K, V>, WireError>

Source§

impl<T, E> FromWire for Result<T, E>
where T: FromWire, E: FromWire,

Source§

fn read_wire( reader: &mut WireReader, index: i32, ) -> Result<Result<T, E>, WireError>

Source§

impl<T> FromWire for Bound<T>
where T: FromWire,

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<Bound<T>, WireError>

Source§

impl<T> FromWire for Box<T>
where T: FromWire,

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<Box<T>, WireError>

Source§

fn read_result_payload( reader: &mut WireReader, index: Option<i32>, ) -> Result<Box<T>, WireError>

Source§

impl<T> FromWire for Option<T>
where T: FromWire,

Source§

fn read_wire( reader: &mut WireReader, index: i32, ) -> Result<Option<T>, WireError>

Source§

impl<T> FromWire for Vec<T>
where T: FromWire,

Source§

fn read_wire(reader: &mut WireReader, index: i32) -> Result<Vec<T>, WireError>

Implementors§