Add DatagramSocket.broadcast property. Fixes #47.

This commit is contained in:
Sönke Ludwig 2018-02-22 02:08:09 +01:00
parent b2b072dd80
commit e8e8f85271

View file

@ -113,6 +113,8 @@ struct DatagramSocket {
this(this) { if (m_fd != DatagramSocketFD.invalid) eventDriver.sockets.addRef(m_fd); }
~this() { if (m_fd != DatagramSocketFD.invalid) eventDriver.sockets.releaseRef(m_fd); }
@property void broadcast(bool enable) { eventDriver.sockets.setBroadcast(m_fd, enable); }
}
void receive(alias callback)(ref DatagramSocket socket, ubyte[] buffer, IOMode mode) {