Laid out concept for UdpSocket init

This commit is contained in:
Jonah Dahlquist 2019-08-13 20:15:14 -05:00 committed by Jonah Dahlquist
commit e8c8e3c9cc
3 changed files with 12 additions and 3 deletions

View file

@ -51,7 +51,7 @@ impl<SpiBus: ActiveBus, NetworkImpl: Network> W5500<SpiBus, NetworkImpl> {
}
pub fn open_udp_socket<SocketImpl: Socket>(&self, socket: SocketImpl) -> UdpSocket<SocketImpl> {
UdpSocket { socket }
UdpSocket::new(socket)
}
}