[][src]Trait libaster::proxy::Request

pub trait Request: Sized + Clone + Debug {
    type Reply: Clone + Debug;
    type HandleCodec: Decoder<Item = Self, Error = Error> + Encoder<Item = Self, Error = Error>;
    type NodeCodec: Decoder<Item = Self::Reply, Error = Error> + Encoder<Item = Self, Error = Error>;
    fn ping_request() -> Self;
fn handle_codec() -> Self::HandleCodec;
fn node_codec() -> Self::NodeCodec;
fn reregister(&self, task: Task);
fn key_hash(&self, hash_tag: &[u8], hasher: fn(_: &[u8]) -> u64) -> u64;
fn subs(&self) -> Option<Vec<Self>>;
fn is_done(&self) -> bool;
fn valid(&self) -> bool;
fn done(&self, data: Self::Reply);
fn done_with_error(&self, err: Error); }

Associated Types

type Reply: Clone + Debug

type HandleCodec: Decoder<Item = Self, Error = Error> + Encoder<Item = Self, Error = Error>

type NodeCodec: Decoder<Item = Self::Reply, Error = Error> + Encoder<Item = Self, Error = Error>

Loading content...

Required methods

fn ping_request() -> Self

fn handle_codec() -> Self::HandleCodec

fn node_codec() -> Self::NodeCodec

fn reregister(&self, task: Task)

fn key_hash(&self, hash_tag: &[u8], hasher: fn(_: &[u8]) -> u64) -> u64

fn subs(&self) -> Option<Vec<Self>>

fn is_done(&self) -> bool

fn valid(&self) -> bool

fn done(&self, data: Self::Reply)

fn done_with_error(&self, err: Error)

Loading content...

Implementors

impl Request for Cmd[src]

type Reply = Resp

type HandleCodec = HandleCodec

type NodeCodec = NodeCodec

Loading content...