// Provides the ability to receive packets asynchronously. Sends are not // buffered since it is acceptable to drop packets under high load. class AsyncUDPSocket : public AsyncPacketSocket { public: // Creates a new socket for sending asynchronous UDP packets using an // asynchronous socket from the given factory. static absl_nullable std::unique_ptr<AsyncUDPSocket> Create( const Environment& env, const SocketAddress& bind_address,
SocketFactory& factory);
State GetState() const override; int GetOption(Socket::Option opt, int* value) override; int SetOption(Socket::Option opt, int value) override; int GetError() const override; void SetError(int error) override;
private: // called when the underlying socket is connected - DTLS handshake case void OnConnectEvent(Socket* socket); // Called when the underlying socket is ready to be read from. void OnReadEvent(Socket* socket); // Called when the underlying socket is ready to send. void OnWriteEvent(Socket* socket);
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.