Go to the documentation of this file.
121 return *(
unsigned char*)
gptr ();
138 DL((
STRMBUF,
"Socketbuf::sys_read() returned %d bytes\n", rval));
148 DL((
STRMBUF,
"Having read %d bytes from socket\n",rval));
157 return (*(
unsigned char*)
gptr ());
214 requested -= xmitted;
219 ::memmove (
pbase (),
pbase () + xmitted, requested);
249 DL((
STRMBUF,
"Buffered IO - allocating %d bytes\n",
260 DL((
STRMBUF,
"Unbuffered IO - same 1 byte array\n"));
virtual int underflow()
This function is called to supply characters for input (from some source) when the get area is empty,...
int get_errno()
Fetch error number in a portable way.
void pbump(int n_)
Advances the next pointer for the output sequence by n_.
char * egptr() const
Returns a pointer just past the end of the get area, the maximum possible value for gptr().
void setp(char *pbeg_, char *pend_)
Set put area pointers.
void setb(char *b_, char *eb_, int del_)
Establish the reserve area (buffer).
char * epptr() const
Returns a pointer just past the end of the put area, the maximum possible value for pptr().
static void dump_to_log(unsigned long mask_, const char *info_, const char *msg_, int len_)
Write hex/ascii dump of a memory region to log file.
char * pptr() const
Returns a pointer to the beginning of the put area, and thus to the location of the next character th...
virtual handler_t getHandler() const =0
Get file descriptor.
@ STRMBUFTRACE
Extended Streambuf & friends messages
void setg(char *gbeg_, char *gnext_, char *gend_)
Set get area pointers.
virtual int doallocate()
This function is called by allocate when unbuffered() is zero and base() is zero.
@ STRMBUF
Class Streambuf & friends messages
int getBytesAvail(void) const
Return number of bytes available in socket receive buffer.
int sys_read(char *b_, int len_)
virtual int showmanyc()
The morphemes of showmanyc are "es-how-many-see", not "show-man-ic".
virtual int overflow(int c_=EOF)
This function is called to consume characters (flush them to output), typically when the put area is ...
Socket * m_s
Reference to the Socket stream.
char * base() const
Returns the lowest possible value for gptr() - the beginning of the get area.
char * pbase() const
Returns a pointer to the beginning fo the space available for the put area, the lowest possible value...
virtual int sync()
This function synchronizes the streambuf with its actual stream of characters.
static const int MAXTCPFRAMESZ
Size of the internal input/output buffer.
int sys_write(char *b_, int len_)
char * gptr() const
Returns a pointer to the beginning of the get area, and thus to the next character to be fetched (if ...
#define trace_with_mask(s, m)