An asynchronous channel for reading, writing, and manipulating an UDP socket.
An asynchronous channel for reading, writing, and manipulating an UDP socket.
On the JVM this is a wrapper around java.nio.channels.DatagramChannel
A Task
based asynchronous channel for reading, writing, and manipulating an UDP socket.
A Task
based asynchronous channel for reading, writing, and manipulating an UDP socket.
On the JVM this is a wrapper around java.nio.channels.DatagramChannel
val ch = TaskDatagramChannel() ch .send(Packet("Hello world!".getBytes("UTF-8")), new InetSocketAddress("localhost", 2115))) .map { len => println(len) ch.close() } .runAsync
Opens a TaskDatagramChannel which can receive packets on the specified UDP port.
Opens a TaskDatagramChannel which can receive packets on the specified UDP port.
hostname
UDP port number