[][src]Struct oxygengine_network::resource::Network

pub struct Network<C> where
    C: Client
{ /* fields omitted */ }

Methods

impl<C> Network<C> where
    C: Client
[src]

pub fn new(version: u32) -> Self[src]

pub fn open_client(&mut self, url: &str) -> Option<ClientID>[src]

pub fn close_client(&mut self, id: ClientID) -> bool[src]

pub fn client(&self, id: ClientID) -> Option<&C>[src]

pub fn client_mut(&mut self, id: ClientID) -> Option<&mut C>[src]

pub fn has_client(&self, id: ClientID) -> bool[src]

pub fn send(
    &mut self,
    id: ClientID,
    msg_id: u32,
    data: &[u8]
) -> Option<Range<usize>>
[src]

pub fn read(
    &self,
    id: ClientID
) -> Option<impl Iterator<Item = (MessageID, &[u8])>>
[src]

pub fn process(&mut self)[src]

Auto Trait Implementations

impl<C> Send for Network<C>

impl<C> Sync for Network<C>

Blanket Implementations

impl<T> From for T[src]

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Any for T where
    T: Any

impl<T> Resource for T where
    T: Any + Send + Sync

impl<T> Event for T where
    T: Send + Sync + 'static, 

impl<T> Erased for T