Go to the documentation of this file.
35 if (_target ==
nullptr) {
38 return send(data, _target,
true);
47 return (_target ==
nullptr || _target->get_socket() ==
nullptr);
56 if (_target !=
nullptr) {
virtual bool is_error()
Returns true if there is an error on the target connection, or if the target has never been set.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
An ordered list of data elements, formatted in memory for transmission over a socket or writing to a ...
DatagramSinkNet(ConnectionManager *manager, int num_threads)
Creates a new DatagramSinkNet with the indicated number of threads to handle writing.
bool send(const Datagram &datagram, const PT(Connection) &connection, bool block=false)
Enqueues a datagram for transmittal on the indicated socket.
virtual void flush()
Ensures that all datagrams previously written will be visible on the stream.
This class handles threaded delivery of datagrams to various TCP or UDP sockets.
The primary interface to the low-level networking layer in this package.
virtual bool put_datagram(const Datagram &data)
Sends the given datagram to the target.