[][src]Trait i3_ipc::I3Protocol

pub trait I3Protocol {
    const MAGIC: &'static str;
    fn _encode_msg<P>(&self, msg: Msg, payload: Option<P>) -> Vec<u8>
    where
        P: AsRef<str>
, { ... }
fn encode_msg(&self, msg: Msg) -> Vec<u8> { ... }
fn encode_msg_body<P>(&self, msg: Msg, payload: P) -> Vec<u8>
    where
        P: AsRef<str>
, { ... }
fn encode_msg_json<P>(&self, msg: Msg, payload: P) -> Result<Vec<u8>, Error>
    where
        P: Serialize
, { ... }
fn decode_event(evt_type: u32, payload: Vec<u8>) -> Result<Event, Error> { ... } }

Associated Constants

const MAGIC: &'static str

Loading content...

Provided methods

fn _encode_msg<P>(&self, msg: Msg, payload: Option<P>) -> Vec<u8> where
    P: AsRef<str>, 

fn encode_msg(&self, msg: Msg) -> Vec<u8>

fn encode_msg_body<P>(&self, msg: Msg, payload: P) -> Vec<u8> where
    P: AsRef<str>, 

fn encode_msg_json<P>(&self, msg: Msg, payload: P) -> Result<Vec<u8>, Error> where
    P: Serialize

fn decode_event(evt_type: u32, payload: Vec<u8>) -> Result<Event, Error>

Loading content...

Implementors

impl<T> I3Protocol for T where
    T: Read + Write
[src]

Loading content...