* more than 1 packet will not work because they will end up with
* different event base to process.
*/
-class AsyncUDPServerSocket : private AsyncUDPSocket::ReadCallback {
+class AsyncUDPServerSocket : private AsyncUDPSocket::ReadCallback
+ , public AsyncSocketBase {
public:
class Callback {
public:
return socket_->address();
}
+ void getAddress(SocketAddress* a) const {
+ *a = address();
+ }
+
/**
* Add a listener to the round robin list
*/
socket_.reset();
}
+ EventBase* getEventBase() const {
+ return evb_;
+ }
+
private:
// AsyncUDPSocket::ReadCallback
void getReadBuffer(void** buf, size_t* len) noexcept {