pub struct ZmqClient { /* private fields */ }
Implementations§
Source§impl ZmqClient
impl ZmqClient
Sourcepub fn new(server_ip: String, server_port: u16) -> Result<Self>
pub fn new(server_ip: String, server_port: u16) -> Result<Self>
Create a new ZMQ connection to the specified server and connect to it
Sourcepub fn server_info(&self) -> (String, u16)
pub fn server_info(&self) -> (String, u16)
Get the server IP and port information
pub fn send(&self, data: &[u8]) -> Result<()>
pub fn receive(&self) -> Result<Vec<u8>>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ZmqClient
impl RefUnwindSafe for ZmqClient
impl Send for ZmqClient
impl !Sync for ZmqClient
impl Unpin for ZmqClient
impl UnwindSafe for ZmqClient
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more