datex_core::network::com_interface

Trait ComInterface

Source
pub trait ComInterface {
    const NAME: &'static str;
    const IN: bool;
    const OUT: bool;
    const GLOBAL: bool;
    const VIRTUAL: bool;

    // Required method
    fn send_block(&mut self, block: &[u8]);
}

Required Associated Constants§

Source

const NAME: &'static str

Source

const IN: bool

Source

const OUT: bool

Source

const GLOBAL: bool

Source

const VIRTUAL: bool

Required Methods§

Source

fn send_block(&mut self, block: &[u8])

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl ComInterface for TCPClientInterface

Source§

const NAME: &'static str = "tcp_client"

Source§

const IN: bool = true

Source§

const OUT: bool = true

Source§

const GLOBAL: bool = true

Source§

const VIRTUAL: bool = false

Source§

impl ComInterface for WebSocketClientInterface

Source§

const NAME: &'static str = "ws_client"

Source§

const IN: bool = true

Source§

const OUT: bool = true

Source§

const GLOBAL: bool = true

Source§

const VIRTUAL: bool = false