[][src]Trait oxygengine_network::client::Client

pub trait Client: Send + Sync + Sized {
    fn open(url: &str) -> Option<Self>;
fn close(self) -> Self;
fn id(&self) -> ClientID;
fn state(&self) -> ClientState;
fn send(&mut self, id: MessageID, data: &[u8]) -> Option<Range<usize>>;
fn receive(&mut self) -> Option<(MessageID, Vec<u8>)>; }

Required methods

fn open(url: &str) -> Option<Self>

fn close(self) -> Self

fn id(&self) -> ClientID

fn state(&self) -> ClientState

fn send(&mut self, id: MessageID, data: &[u8]) -> Option<Range<usize>>

fn receive(&mut self) -> Option<(MessageID, Vec<u8>)>

Loading content...

Implementations on Foreign Types

impl Client for ()[src]

Loading content...

Implementors

Loading content...