14#ifndef DATAGRAMSINKNET_H
15#define DATAGRAMSINKNET_H
30 INLINE
void set_target(Connection *connection);
39 PT(Connection) _target;
ConnectionWriter(ConnectionManager *manager, int num_threads, const std::string &thread_name=std::string())
Creates a new ConnectionWriter with the indicated number of threads to handle output.
void set_target(Connection *connection)
Specifies the Connection that will receive all future Datagrams sent.
virtual void flush()
Ensures that all datagrams previously written will be visible on the stream.
DatagramSinkNet(ConnectionManager *manager, int num_threads)
Creates a new DatagramSinkNet with the indicated number of threads to handle writing.
virtual bool is_error()
Returns true if there is an error on the target connection, or if the target has never been set.
Connection * get_target() const
Returns the current target Connection, or NULL if the target has not yet been set.
virtual bool put_datagram(const Datagram &data)
Sends the given datagram to the target.
DatagramSink()
Does nothing since this is class is just the definition of an interface.
An ordered list of data elements, formatted in memory for transmission over a socket or writing to a ...
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.