[−][src]Struct runng::socket::NngSocket
Wraps nng_socket
. See nng_socket.
Methods
impl NngSocket
[src]
pub fn new(socket: nng_socket) -> Self
[src]
Create a new NngSocket
.
pub unsafe fn nng_socket(&self) -> nng_socket
[src]
Obtain underlying nng_socket
pub fn notify(
&self,
event: nng_pipe_ev,
callback: PipeNotifyCallback,
argument: PipeNotifyCallbackArg
) -> Result<()>
[src]
&self,
event: nng_pipe_ev,
callback: PipeNotifyCallback,
argument: PipeNotifyCallbackArg
) -> Result<()>
Register pipe notification callback. See nng_pipe_notify.
Trait Implementations
impl Clone for NngSocket
[src]
fn clone(&self) -> Self
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Debug for NngSocket
[src]
impl GetSocket for NngSocket
[src]
fn socket(&self) -> &NngSocket
[src]
fn socket_mut(&mut self) -> &mut NngSocket
[src]
unsafe fn nng_socket(&self) -> nng_socket
[src]
impl RecvSocket for NngSocket
[src]
fn recv<'a>(&self, buffer: &'a mut [u8]) -> Result<&'a [u8]>
[src]
fn recv_flags<'a>(&self, buffer: &'a mut [u8], flags: Flags) -> Result<&'a [u8]>
[src]
fn recv_zerocopy(&self) -> Result<Alloc>
[src]
fn recv_zerocopy_flags(&self, flags: Flags) -> Result<Alloc>
[src]
fn recvmsg(&self) -> Result<NngMsg>
[src]
fn recvmsg_flags(&self, flags: Flags) -> Result<NngMsg>
[src]
impl SendSocket for NngSocket
[src]
fn send(&self, data: &[u8]) -> Result<()>
[src]
fn send_flags(&self, data: &[u8], flags: Flags) -> Result<()>
[src]
fn send_zerocopy(&self, data: Alloc) -> Result<(), SendError<Alloc>>
[src]
fn send_zerocopy_flags(
&self,
data: Alloc,
flags: Flags
) -> Result<(), SendError<Alloc>>
[src]
&self,
data: Alloc,
flags: Flags
) -> Result<(), SendError<Alloc>>
fn sendmsg(&self, msg: NngMsg) -> Result<()>
[src]
fn sendmsg_flags(
&self,
msg: NngMsg,
flags: Flags
) -> Result<(), SendError<NngMsg>>
[src]
&self,
msg: NngMsg,
flags: Flags
) -> Result<(), SendError<NngMsg>>
impl Socket for NngSocket
[src]
Auto Trait Implementations
impl RefUnwindSafe for NngSocket
impl Send for NngSocket
impl Sync for NngSocket
impl Unpin for NngSocket
impl UnwindSafe for NngSocket
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,