Sophie

Sophie

distrib > Mandriva > 2007.0 > i586 > by-pkgid > ad1ba1135a9c9eeffc2e538163e00373 > files > 774

libCommonC++2_1.4-devel-1.4.1-1mdv2007.0.i586.rpm

\section{ost::TCPStream Class Reference}
\label{classost_1_1_t_c_p_stream}\index{ost::TCPStream@{ost::TCPStream}}
TCP streams are used to represent TCP client connections to a server by TCP protocol servers for accepting client connections.streamable TCP socket connection.  


{\tt \#include $<$socket.h$>$}

Inheritance diagram for ost::TCPStream::\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[height=3cm]{classost_1_1_t_c_p_stream}
\end{center}
\end{figure}
\subsection*{Public Member Functions}
\begin{CompactItemize}
\item 
{\bf TCPStream} ({\bf Family} {\bf family}=IPV4, bool throwflag=true, {\bf timeout\_\-t} to=0)
\begin{CompactList}\small\item\em The constructor required for building other classes or to start an unconnected {\bf TCPStream}{\rm (p.\,\pageref{classost_1_1_t_c_p_stream})} for connect. \item\end{CompactList}\item 
void {\bf disconnect} (void)
\begin{CompactList}\small\item\em Disconnect the current session and prepare for a new one. \item\end{CompactList}\item 
int {\bf get\-Segment\-Size} (void)
\begin{CompactList}\small\item\em Get protocol segment size. \item\end{CompactList}\item 
{\bf TCPStream} ({\bf TCPSocket} \&server, bool throwflag=true, {\bf timeout\_\-t} {\bf timeout}=0)
\begin{CompactList}\small\item\em Create a TCP stream by accepting a connection from a bound TCP socket acting as a server. \item\end{CompactList}\item 
{\bf TCPStream} ({\bf TCPV6Socket} \&server, bool throwflag=true, {\bf timeout\_\-t} {\bf timeout}=0)
\item 
void {\bf connect} ({\bf TCPSocket} \&server)
\begin{CompactList}\small\item\em Accept a connection from a TCP Server. \item\end{CompactList}\item 
void {\bf connect} ({\bf TCPV6Socket} \&server)
\item 
{\bf TCPStream} (const {\bf IPV4Host} \&host, {\bf tpport\_\-t} port, unsigned mss=536, bool throwflag=true, {\bf timeout\_\-t} {\bf timeout}=0)
\begin{CompactList}\small\item\em Create a TCP stream by connecting to a TCP socket (on a remote machine). \item\end{CompactList}\item 
{\bf TCPStream} (const {\bf IPV6Host} \&host, {\bf tpport\_\-t} port, unsigned mss=536, bool throwflag=true, {\bf timeout\_\-t} {\bf timeout}=0)
\item 
{\bf TCPStream} (const char $\ast$name, {\bf Family} {\bf family}=IPV4, unsigned mss=536, bool throwflag=false, {\bf timeout\_\-t} timer=0)
\begin{CompactList}\small\item\em Construct a named TCP {\bf Socket}{\rm (p.\,\pageref{classost_1_1_socket})} connected to a remote machine. \item\end{CompactList}\item 
void {\bf set\-Timeout} ({\bf timeout\_\-t} timer)
\begin{CompactList}\small\item\em Set the I/O operation timeout for socket I/O operations. \item\end{CompactList}\item 
{\bf TCPStream} (const {\bf TCPStream} \&source)
\begin{CompactList}\small\item\em A copy constructor creates a new stream buffer. \item\end{CompactList}\item 
virtual {\bf $\sim$TCPStream} ()
\begin{CompactList}\small\item\em Flush and empty all buffers, and then remove the allocated buffers. \item\end{CompactList}\item 
int {\bf sync} (void)
\begin{CompactList}\small\item\em Flushes the stream input and output buffers, writes pending output. \item\end{CompactList}\item 
size\_\-t {\bf printf} (const char $\ast$format,...)
\begin{CompactList}\small\item\em Print content into a socket. \item\end{CompactList}\item 
bool {\bf is\-Pending} ({\bf Pending} pend, {\bf timeout\_\-t} {\bf timeout}=TIMEOUT\_\-INF)
\begin{CompactList}\small\item\em Get the status of pending stream data. \item\end{CompactList}\item 
ssize\_\-t {\bf peek} (void $\ast$buf, size\_\-t len)
\begin{CompactList}\small\item\em Examine contents of next waiting packet. \item\end{CompactList}\item 
size\_\-t {\bf get\-Buffer\-Size} (void) const 
\begin{CompactList}\small\item\em Return the size of the current stream buffering used. \item\end{CompactList}\end{CompactItemize}
\subsection*{Protected Member Functions}
\begin{CompactItemize}
\item 
void {\bf allocate} (size\_\-t size)
\begin{CompactList}\small\item\em Used to allocate the buffer space needed for iostream operations. \item\end{CompactList}\item 
void {\bf end\-Stream} (void)
\begin{CompactList}\small\item\em Used to terminate the buffer space and cleanup the socket connection. \item\end{CompactList}\item 
int {\bf underflow} ()
\begin{CompactList}\small\item\em This streambuf method is used to load the input buffer through the established tcp socket connection. \item\end{CompactList}\item 
int {\bf uflow} ()
\begin{CompactList}\small\item\em This streambuf method is used for doing unbuffered reads through the establish tcp socket connection when in interactive mode. \item\end{CompactList}\item 
int {\bf overflow} (int ch)
\begin{CompactList}\small\item\em This streambuf method is used to write the output buffer through the established tcp connection. \item\end{CompactList}\item 
void {\bf connect} (const {\bf IPV4Host} \&host, {\bf tpport\_\-t} port, unsigned mss=536)
\begin{CompactList}\small\item\em Create a TCP stream by connecting to a TCP socket (on a remote machine). \item\end{CompactList}\item 
void {\bf connect} (const {\bf IPV6Host} \&host, {\bf tpport\_\-t} port, unsigned mss=536)
\item 
void {\bf connect} (const char $\ast$name, unsigned mss=536)
\begin{CompactList}\small\item\em Connect a TCP stream to a named destination host and port number, using getaddrinfo interface if available. \item\end{CompactList}\item 
std::iostream $\ast$ {\bf tcp} (void)
\begin{CompactList}\small\item\em Used in derived classes to refer to the current object via it's iostream. \item\end{CompactList}\end{CompactItemize}
\subsection*{Protected Attributes}
\begin{CompactItemize}
\item 
{\bf timeout\_\-t} {\bf timeout}
\item 
size\_\-t {\bf bufsize}
\item 
{\bf Family} {\bf family}
\item 
char $\ast$ {\bf gbuf}
\item 
char $\ast$ {\bf pbuf}
\end{CompactItemize}
\subsection*{Friends}
\begin{CompactItemize}
\item 
{\bf TCPStream} \& {\bf crlf} ({\bf TCPStream} \&)
\item 
{\bf TCPStream} \& {\bf lfcr} ({\bf TCPStream} \&)
\end{CompactItemize}


\subsection{Detailed Description}
TCP streams are used to represent TCP client connections to a server by TCP protocol servers for accepting client connections.streamable TCP socket connection. 

The TCP stream is a C++ \char`\"{}stream\char`\"{} class, and can accept streaming of data to and from other C++ objects using the $<$$<$ and $>$$>$ operators.

{\bf TCPStream}{\rm (p.\,\pageref{classost_1_1_t_c_p_stream})} itself can be formed either by connecting to a bound network address of a TCP server, or can be created when \char`\"{}accepting\char`\"{} a network connection from a TCP server.

\begin{Desc}
\item[Author:]David Sugar $<${\tt dyfet@ostel.com}$>$ \end{Desc}
\begin{Desc}
\item[Examples: ]\par


{\bf tcp.cpp}, and {\bf tcpstr1.cpp}.\end{Desc}




\subsection{Constructor \& Destructor Documentation}
\index{ost::TCPStream@{ost::TCPStream}!TCPStream@{TCPStream}}
\index{TCPStream@{TCPStream}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}ost::TCPStream::TCPStream ({\bf Family} {\em family} = {\tt IPV4}, bool {\em throwflag} = {\tt true}, {\bf timeout\_\-t} {\em to} = {\tt 0})}\label{classost_1_1_t_c_p_stream_a2ee8f719d30376c22ce9503baa9f43c}


The constructor required for building other classes or to start an unconnected {\bf TCPStream}{\rm (p.\,\pageref{classost_1_1_t_c_p_stream})} for connect. 

\index{ost::TCPStream@{ost::TCPStream}!TCPStream@{TCPStream}}
\index{TCPStream@{TCPStream}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}ost::TCPStream::TCPStream ({\bf TCPSocket} \& {\em server}, bool {\em throwflag} = {\tt true}, {\bf timeout\_\-t} {\em timeout} = {\tt 0})}\label{classost_1_1_t_c_p_stream_8e008d40cdf19e3216cce66dfd084991}


Create a TCP stream by accepting a connection from a bound TCP socket acting as a server. 

This performs an \char`\"{}accept\char`\"{} call.

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em server}]socket listening \item[{\em throwflag}]flag to throw errors. \item[{\em timeout}]for all operations. \end{description}
\end{Desc}
\index{ost::TCPStream@{ost::TCPStream}!TCPStream@{TCPStream}}
\index{TCPStream@{TCPStream}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}ost::TCPStream::TCPStream ({\bf TCPV6Socket} \& {\em server}, bool {\em throwflag} = {\tt true}, {\bf timeout\_\-t} {\em timeout} = {\tt 0})}\label{classost_1_1_t_c_p_stream_24bea89abbc213b6f60918ee233c6437}


\index{ost::TCPStream@{ost::TCPStream}!TCPStream@{TCPStream}}
\index{TCPStream@{TCPStream}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}ost::TCPStream::TCPStream (const {\bf IPV4Host} \& {\em host}, {\bf tpport\_\-t} {\em port}, unsigned {\em mss} = {\tt 536}, bool {\em throwflag} = {\tt true}, {\bf timeout\_\-t} {\em timeout} = {\tt 0})}\label{classost_1_1_t_c_p_stream_3aed78339f5695c1b281a59473628cb5}


Create a TCP stream by connecting to a TCP socket (on a remote machine). 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em host}]address of remote TCP server. \item[{\em port}]number to connect. \item[{\em mss}]maximum segment size of streaming buffers. \item[{\em throwflag}]flag to throw errors. \item[{\em timeout}]for all operations. \end{description}
\end{Desc}
\index{ost::TCPStream@{ost::TCPStream}!TCPStream@{TCPStream}}
\index{TCPStream@{TCPStream}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}ost::TCPStream::TCPStream (const {\bf IPV6Host} \& {\em host}, {\bf tpport\_\-t} {\em port}, unsigned {\em mss} = {\tt 536}, bool {\em throwflag} = {\tt true}, {\bf timeout\_\-t} {\em timeout} = {\tt 0})}\label{classost_1_1_t_c_p_stream_404f9e717f04b2d68fecd61b246b8ead}


\index{ost::TCPStream@{ost::TCPStream}!TCPStream@{TCPStream}}
\index{TCPStream@{TCPStream}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}ost::TCPStream::TCPStream (const char $\ast$ {\em name}, {\bf Family} {\em family} = {\tt IPV4}, unsigned {\em mss} = {\tt 536}, bool {\em throwflag} = {\tt false}, {\bf timeout\_\-t} {\em timer} = {\tt 0})}\label{classost_1_1_t_c_p_stream_744b09288892788e8b7f0453850d3562}


Construct a named TCP {\bf Socket}{\rm (p.\,\pageref{classost_1_1_socket})} connected to a remote machine. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em name}]of remote service. \item[{\em family}]of protocol. \item[{\em mss}]maximum segment size of streaming buffers. \item[{\em throwflag}]flag to throw errors. \item[{\em timer}]for timeout for all operations. \end{description}
\end{Desc}
\index{ost::TCPStream@{ost::TCPStream}!TCPStream@{TCPStream}}
\index{TCPStream@{TCPStream}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}ost::TCPStream::TCPStream (const {\bf TCPStream} \& {\em source})}\label{classost_1_1_t_c_p_stream_35ce0f9982969a1fe9ab2fa583802945}


A copy constructor creates a new stream buffer. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em source}]reference of stream to copy from. \end{description}
\end{Desc}
\index{ost::TCPStream@{ost::TCPStream}!~TCPStream@{$\sim$TCPStream}}
\index{~TCPStream@{$\sim$TCPStream}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}virtual ost::TCPStream::$\sim$TCPStream ()\hspace{0.3cm}{\tt  [virtual]}}\label{classost_1_1_t_c_p_stream_ebd30d743538f2c3d95e2b1d214f176b}


Flush and empty all buffers, and then remove the allocated buffers. 



\subsection{Member Function Documentation}
\index{ost::TCPStream@{ost::TCPStream}!allocate@{allocate}}
\index{allocate@{allocate}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void ost::TCPStream::allocate (size\_\-t {\em size})\hspace{0.3cm}{\tt  [protected]}}\label{classost_1_1_t_c_p_stream_c223dac737c08d1b109bdc06be0b5493}


Used to allocate the buffer space needed for iostream operations. 

This function is called by the constructor.

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em size}]of stream buffers from constructor. \end{description}
\end{Desc}
\index{ost::TCPStream@{ost::TCPStream}!connect@{connect}}
\index{connect@{connect}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void ost::TCPStream::connect ({\bf TCPV6Socket} \& {\em server})}\label{classost_1_1_t_c_p_stream_ba5de9163b215f181a43903099a8c403}


\index{ost::TCPStream@{ost::TCPStream}!connect@{connect}}
\index{connect@{connect}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void ost::TCPStream::connect ({\bf TCPSocket} \& {\em server})}\label{classost_1_1_t_c_p_stream_75ef0dedbc6985ff113817a24cb8fc14}


Accept a connection from a TCP Server. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em server}]socket listening \end{description}
\end{Desc}
\index{ost::TCPStream@{ost::TCPStream}!connect@{connect}}
\index{connect@{connect}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void ost::TCPStream::connect (const char $\ast$ {\em name}, unsigned {\em mss} = {\tt 536})\hspace{0.3cm}{\tt  [protected]}}\label{classost_1_1_t_c_p_stream_17ec811f69da42d9c6f2d5b940dc54e0}


Connect a TCP stream to a named destination host and port number, using getaddrinfo interface if available. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em name}]of host and service to connect \item[{\em mss}]maximum segment size of stream buffer \end{description}
\end{Desc}
\index{ost::TCPStream@{ost::TCPStream}!connect@{connect}}
\index{connect@{connect}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void ost::TCPStream::connect (const {\bf IPV6Host} \& {\em host}, {\bf tpport\_\-t} {\em port}, unsigned {\em mss} = {\tt 536})\hspace{0.3cm}{\tt  [protected]}}\label{classost_1_1_t_c_p_stream_a2f4de4c7606cc893d16fa28efb7f438}


\index{ost::TCPStream@{ost::TCPStream}!connect@{connect}}
\index{connect@{connect}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void ost::TCPStream::connect (const {\bf IPV4Host} \& {\em host}, {\bf tpport\_\-t} {\em port}, unsigned {\em mss} = {\tt 536})\hspace{0.3cm}{\tt  [protected]}}\label{classost_1_1_t_c_p_stream_39d12c649b784cf83dfbd36581f27d8c}


Create a TCP stream by connecting to a TCP socket (on a remote machine). 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em host}]address of remote TCP server. \item[{\em port}]number to connect. \item[{\em mss}]maximum segment size of streaming buffers. \end{description}
\end{Desc}
\begin{Desc}
\item[Examples: ]\par
{\bf tcp.cpp}.\end{Desc}
\index{ost::TCPStream@{ost::TCPStream}!disconnect@{disconnect}}
\index{disconnect@{disconnect}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void ost::TCPStream::disconnect (void)}\label{classost_1_1_t_c_p_stream_465c1772f8b6c1e1effcdfdc248622af}


Disconnect the current session and prepare for a new one. 

\begin{Desc}
\item[Examples: ]\par
{\bf tcp.cpp}, and {\bf tcpstr1.cpp}.\end{Desc}
\index{ost::TCPStream@{ost::TCPStream}!endStream@{endStream}}
\index{endStream@{endStream}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void ost::TCPStream::end\-Stream (void)\hspace{0.3cm}{\tt  [protected]}}\label{classost_1_1_t_c_p_stream_d64fb34a2a8003fac17a471060e89b39}


Used to terminate the buffer space and cleanup the socket connection. 

This fucntion is called by the destructor. \index{ost::TCPStream@{ost::TCPStream}!getBufferSize@{getBufferSize}}
\index{getBufferSize@{getBufferSize}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}size\_\-t ost::TCPStream::get\-Buffer\-Size (void) const\hspace{0.3cm}{\tt  [inline]}}\label{classost_1_1_t_c_p_stream_0d016d7c968dcfcb0d3e15e759af4c5f}


Return the size of the current stream buffering used. 

\begin{Desc}
\item[Returns:]size of stream buffers. \end{Desc}
\index{ost::TCPStream@{ost::TCPStream}!getSegmentSize@{getSegmentSize}}
\index{getSegmentSize@{getSegmentSize}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int ost::TCPStream::get\-Segment\-Size (void)}\label{classost_1_1_t_c_p_stream_4c5fac74099d34d067b075995f53b60a}


Get protocol segment size. 

\begin{Desc}
\item[Examples: ]\par
{\bf tcp.cpp}.\end{Desc}
\index{ost::TCPStream@{ost::TCPStream}!isPending@{isPending}}
\index{isPending@{isPending}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool ost::TCPStream::is\-Pending ({\bf Pending} {\em pend}, {\bf timeout\_\-t} {\em timeout} = {\tt TIMEOUT\_\-INF})}\label{classost_1_1_t_c_p_stream_eb71ab0a1a1ff92095e5421701649ad2}


Get the status of pending stream data. 

This can be used to examine if input or output is waiting, or if an error or disconnect has occured on the stream. If a read buffer contains data then input is ready and if write buffer contains data it is first flushed and then checked. \begin{Desc}
\item[Examples: ]\par
{\bf tcp.cpp}.\end{Desc}
\index{ost::TCPStream@{ost::TCPStream}!overflow@{overflow}}
\index{overflow@{overflow}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int ost::TCPStream::overflow (int {\em ch})\hspace{0.3cm}{\tt  [protected]}}\label{classost_1_1_t_c_p_stream_5be264ef6d4972f0c213aed20d233bbf}


This streambuf method is used to write the output buffer through the established tcp connection. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em ch}]char to push through. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]char pushed through. \end{Desc}
\index{ost::TCPStream@{ost::TCPStream}!peek@{peek}}
\index{peek@{peek}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}ssize\_\-t ost::TCPStream::peek (void $\ast$ {\em buf}, size\_\-t {\em len})\hspace{0.3cm}{\tt  [inline]}}\label{classost_1_1_t_c_p_stream_0150df4f03d32e200b22d0f06404ac39}


Examine contents of next waiting packet. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em buf}]pointer to packet buffer for contents. \item[{\em len}]of packet buffer. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]number of bytes examined. \end{Desc}
\index{ost::TCPStream@{ost::TCPStream}!printf@{printf}}
\index{printf@{printf}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}size\_\-t ost::TCPStream::printf (const char $\ast$ {\em format},  {\em ...})}\label{classost_1_1_t_c_p_stream_b418e62f385b62680825beaf79c00df4}


Print content into a socket. 

\begin{Desc}
\item[Returns:]count of bytes sent. \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em format}]string \end{description}
\end{Desc}
\index{ost::TCPStream@{ost::TCPStream}!setTimeout@{setTimeout}}
\index{setTimeout@{setTimeout}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void ost::TCPStream::set\-Timeout ({\bf timeout\_\-t} {\em timer})\hspace{0.3cm}{\tt  [inline]}}\label{classost_1_1_t_c_p_stream_1bdf8e7962c57d6086117d5a790ad3f6}


Set the I/O operation timeout for socket I/O operations. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em timer}]to change timeout. \end{description}
\end{Desc}


Reimplemented in {\bf ost::URLStream} {\rm (p.\,\pageref{classost_1_1_u_r_l_stream_82863fbf49c6095877c2147a670e3e71})}.\index{ost::TCPStream@{ost::TCPStream}!sync@{sync}}
\index{sync@{sync}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int ost::TCPStream::sync (void)}\label{classost_1_1_t_c_p_stream_75847ccff483b077c3b7c57b03a5175b}


Flushes the stream input and output buffers, writes pending output. 

\begin{Desc}
\item[Returns:]0 on success. \end{Desc}
\index{ost::TCPStream@{ost::TCPStream}!tcp@{tcp}}
\index{tcp@{tcp}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}std::iostream$\ast$ ost::TCPStream::tcp (void)\hspace{0.3cm}{\tt  [inline, protected]}}\label{classost_1_1_t_c_p_stream_5191b9c6d7c2369f96f236ae78b25452}


Used in derived classes to refer to the current object via it's iostream. 

For example, to send a set of characters in a derived method, one might use $\ast$tcp() $<$$<$ \char`\"{}test\char`\"{}.

\begin{Desc}
\item[Returns:]stream pointer of this object. \end{Desc}
\index{ost::TCPStream@{ost::TCPStream}!uflow@{uflow}}
\index{uflow@{uflow}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int ost::TCPStream::uflow ()\hspace{0.3cm}{\tt  [protected]}}\label{classost_1_1_t_c_p_stream_9c1c5fa96fd3dc099ef452691075e492}


This streambuf method is used for doing unbuffered reads through the establish tcp socket connection when in interactive mode. 

Also this method will handle proper use of buffers if not in interative mode.

\begin{Desc}
\item[Returns:]char from tcp socket connection, EOF if not connected. \end{Desc}
\index{ost::TCPStream@{ost::TCPStream}!underflow@{underflow}}
\index{underflow@{underflow}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int ost::TCPStream::underflow ()\hspace{0.3cm}{\tt  [protected]}}\label{classost_1_1_t_c_p_stream_8bba1f2724c35992a48ef7322214a3dc}


This streambuf method is used to load the input buffer through the established tcp socket connection. 

\begin{Desc}
\item[Returns:]char from get buffer, EOF if not connected. \end{Desc}


Reimplemented in {\bf ost::URLStream} {\rm (p.\,\pageref{classost_1_1_u_r_l_stream_0dc12a6f57c7ba5d05988dcc12fd41cf})}.

\subsection{Friends And Related Function Documentation}
\index{ost::TCPStream@{ost::TCPStream}!crlf@{crlf}}
\index{crlf@{crlf}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf TCPStream}\& crlf ({\bf TCPStream} \&)\hspace{0.3cm}{\tt  [friend]}}\label{classost_1_1_t_c_p_stream_203329196708b27f1e703e8c6b274490}


\index{ost::TCPStream@{ost::TCPStream}!lfcr@{lfcr}}
\index{lfcr@{lfcr}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf TCPStream}\& lfcr ({\bf TCPStream} \&)\hspace{0.3cm}{\tt  [friend]}}\label{classost_1_1_t_c_p_stream_83209402df6507effb431cca0e8f06cc}




\subsection{Member Data Documentation}
\index{ost::TCPStream@{ost::TCPStream}!bufsize@{bufsize}}
\index{bufsize@{bufsize}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}size\_\-t {\bf ost::TCPStream::bufsize}\hspace{0.3cm}{\tt  [protected]}}\label{classost_1_1_t_c_p_stream_1eb7fe5844a5c0a5708d658187e9839b}


\index{ost::TCPStream@{ost::TCPStream}!family@{family}}
\index{family@{family}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf Family} {\bf ost::TCPStream::family}\hspace{0.3cm}{\tt  [protected]}}\label{classost_1_1_t_c_p_stream_ecc5f6b34232ba0fef048f53fdaa51fc}


\index{ost::TCPStream@{ost::TCPStream}!gbuf@{gbuf}}
\index{gbuf@{gbuf}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}char$\ast$ {\bf ost::TCPStream::gbuf}\hspace{0.3cm}{\tt  [protected]}}\label{classost_1_1_t_c_p_stream_6e0d7b50899682ff1997239b85427469}


\index{ost::TCPStream@{ost::TCPStream}!pbuf@{pbuf}}
\index{pbuf@{pbuf}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}char $\ast$ {\bf ost::TCPStream::pbuf}\hspace{0.3cm}{\tt  [protected]}}\label{classost_1_1_t_c_p_stream_fe373d1dd6090f4627e2361ff3a4fcdd}


\index{ost::TCPStream@{ost::TCPStream}!timeout@{timeout}}
\index{timeout@{timeout}!ost::TCPStream@{ost::TCPStream}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf timeout\_\-t} {\bf ost::TCPStream::timeout}\hspace{0.3cm}{\tt  [protected]}}\label{classost_1_1_t_c_p_stream_e223ae380e2dc9d2e64cde0a577eccf2}




The documentation for this class was generated from the following file:\begin{CompactItemize}
\item 
{\bf socket.h}\end{CompactItemize}