impl Debug for SocketSet.
This commit is contained in:
parent
4b92c25fa3
commit
9fb6d6f4b2
|
@ -41,6 +41,7 @@ pub use self::set::{Iter as SocketSetIter, IterMut as SocketSetIterMut};
|
||||||
/// which is rather inelegant. Conversely, when `dispatch` is called, the packet length is
|
/// which is rather inelegant. Conversely, when `dispatch` is called, the packet length is
|
||||||
/// not yet known and the packet storage has to be allocated; but the `&PacketRepr` is sufficient
|
/// not yet known and the packet storage has to be allocated; but the `&PacketRepr` is sufficient
|
||||||
/// since the lower layers treat the packet as an opaque octet sequence.
|
/// since the lower layers treat the packet as an opaque octet sequence.
|
||||||
|
#[derive(Debug)]
|
||||||
pub enum Socket<'a, 'b: 'a> {
|
pub enum Socket<'a, 'b: 'a> {
|
||||||
Udp(UdpSocket<'a, 'b>),
|
Udp(UdpSocket<'a, 'b>),
|
||||||
Tcp(TcpSocket<'a>),
|
Tcp(TcpSocket<'a>),
|
||||||
|
|
|
@ -10,6 +10,7 @@ pub struct Handle {
|
||||||
}
|
}
|
||||||
|
|
||||||
/// An extensible set of sockets, with stable numeric identifiers.
|
/// An extensible set of sockets, with stable numeric identifiers.
|
||||||
|
#[derive(Debug)]
|
||||||
pub struct Set<'a, 'b: 'a, 'c: 'a + 'b> {
|
pub struct Set<'a, 'b: 'a, 'c: 'a + 'b> {
|
||||||
sockets: ManagedSlice<'a, Option<Socket<'b, 'c>>>
|
sockets: ManagedSlice<'a, Option<Socket<'b, 'c>>>
|
||||||
}
|
}
|
||||||
|
|
|
@ -107,6 +107,7 @@ impl<'a, 'b> SocketBuffer<'a, 'b> {
|
||||||
///
|
///
|
||||||
/// An UDP socket is bound to a specific endpoint, and owns transmit and receive
|
/// An UDP socket is bound to a specific endpoint, and owns transmit and receive
|
||||||
/// packet buffers.
|
/// packet buffers.
|
||||||
|
#[derive(Debug)]
|
||||||
pub struct UdpSocket<'a, 'b: 'a> {
|
pub struct UdpSocket<'a, 'b: 'a> {
|
||||||
endpoint: IpEndpoint,
|
endpoint: IpEndpoint,
|
||||||
rx_buffer: SocketBuffer<'a, 'b>,
|
rx_buffer: SocketBuffer<'a, 'b>,
|
||||||
|
|
Loading…
Reference in New Issue