Panda3D
|
A base class for iostreams that read and write to a (possibly non-blocking) socket. More...
#include <pandadoc.hpp>
Public Member Functions | |
close () | |
bool | flush () |
Sends the most recently queued data now. More... | |
int | getTcpHeaderSize () |
Returns the header size for datagrams. More... | |
bool | isClosed () |
setTcpHeaderSize (int tcp_header_size) | |
Sets the header size for datagrams. More... | |
![]() | |
flush () | |
![]() | |
int | get () |
seekg (Streamoff off, IosBase::Seekdir dir) | |
seekg (Streamoff pos) | |
Streamoff | tellg () |
![]() | |
bool | bad () |
clear () | |
bool | eof () |
bool | fail () |
bool | good () |
![]() | |
flush () | |
put (char c) | |
seekp (Streamoff off, IosBase::Seekdir dir) | |
seekp (Streamoff pos) | |
Streamoff | tellp () |
![]() | |
close () | |
int | getTcpHeaderSize () |
Returns the header size for datagrams. More... | |
bool | isClosed () |
bool | receiveDatagram (Datagram dg) |
Receives a datagram over the socket by expecting a little-endian 16-bit byte count as a prefix. More... | |
setTcpHeaderSize (int tcp_header_size) | |
Sets the header size for datagrams. More... | |
![]() | |
close () | |
bool | considerFlush () |
Sends the most recently queued data if enough time has elapsed. More... | |
bool | flush () |
Sends the most recently queued data now. More... | |
bool | getCollectTcp () |
Returns the current setting of "collect-tcp" mode. More... | |
double | getCollectTcpInterval () |
Returns the interval in time, in seconds, for which to hold TCP packets before sending all of the recently received packets at once. More... | |
int | getTcpHeaderSize () |
Returns the header size for datagrams. More... | |
bool | isClosed () |
bool | sendDatagram (const Datagram dg) |
Transmits the indicated datagram over the socket by prepending it with a little-endian 16-bit byte count. More... | |
setCollectTcp (bool collect_tcp) | |
Enables or disables "collect-tcp" mode. More... | |
setCollectTcpInterval (double interval) | |
Specifies the interval in time, in seconds, for which to hold TCP packets before sending all of the recently received packets at once. More... | |
setTcpHeaderSize (int tcp_header_size) | |
Sets the header size for datagrams. More... | |
Additional Inherited Members | |
![]() | |
enum | Iostate |
enum | Openmode |
enum | Seekdir { beg = 0 , cur = 1 , end = 2 } |
A base class for iostreams that read and write to a (possibly non-blocking) socket.
close | ( | ) |
bool flush | ( | ) |
Sends the most recently queued data now.
This only has meaning if set_collect_tcp() has been set to true.
int getTcpHeaderSize | ( | ) |
Returns the header size for datagrams.
See set_tcp_header_size().
bool isClosed | ( | ) |
setTcpHeaderSize | ( | int | tcp_header_size | ) |
Sets the header size for datagrams.
At the present, legal values for this are 0, 2, or 4; this specifies the number of bytes to use encode the datagram length at the start of each TCP datagram. Sender and receiver must independently agree on this.