Struct nat_traversal::MappedUdpSocket
[−]
[src]
pub struct MappedUdpSocket { pub socket: UdpSocket, pub endpoints: Vec<MappedSocketAddr>, }
A bound udp socket for which we know our external endpoints.
Fields
socket: UdpSocket
The socket.
endpoints: Vec<MappedSocketAddr>
The known endpoints of this socket.
Methods
impl MappedUdpSocket
[src]
fn map(socket: UdpSocket, mc: &MappingContext) -> WResult<MappedUdpSocket, MappedUdpSocketMapWarning, MappedUdpSocketMapError>
Map an existing UdpSocket
.
fn new(mc: &MappingContext) -> WResult<MappedUdpSocket, MappedUdpSocketMapWarning, MappedUdpSocketNewError>
Create a new MappedUdpSocket