pub fn recv_slice(&mut self, data: &mut [u8]) -> Result<(usize, IpAddress)> {
        let (buffer, endpoint) = self.recv()?;
        let length = cmp::min(data.len(), buffer.len());
        data[..length].copy_from_slice(&buffer[..length]);
        Ok((length, endpoint))
    }
/// Dequeue a packet received from a remote endpoint, copy the payload into the given slice,
/// and return the amount of octets copied as well as the `IpAddress`
///
/// See also [recv](#method.recv).
Dequeue a packet received from a remote endpoint, copy the payload into the given slice,
and return the amount of octets copied as well as the `IpAddress`


Dequeue a packet received from a remote endpoint copy the payload into the given slice and return the amount of octets copied as well as the ` IpAddress `
pub fn recv_slice(&mut self, data: &mut [u8]) -> Result<(usize, IpAddress)> {
        let (buffer, endpoint) = self.recv()?;
        let length = cmp::min(data.len(), buffer.len());
        data[..length].copy_from_slice(&buffer[..length]);
        Ok((length, endpoint))
    }
pub fn recv_slice ( & mut self , data : & mut [ u8 ] ) -> Result < ( usize , IpAddress ) > { let ( buffer , endpoint ) = self . recv ( ) ? ; let length = cmp :: min ( data . len ( ) , buffer . len ( ) ) ; data [ .. length ] . copy_from_slice ( & buffer [ .. length ] ) ; Ok ( ( length , endpoint ) ) }
Dequeue a packet received from a remote endpoint, copy the payload into the given slice,
and return the amount of octets copied as well as the `IpAddress`
Dequeue a packet received from a remote endpoint copy the payload into the given slice and return the amount of octets copied as well as the ` IpAddress `
&mut self
data
&mut [u8]
&mut self
data
&mut [u8]