\section{KIO::Connection Class Reference}
\label{classKIO_1_1Connection}\index{KIO::Connection@{KIO::Connection}}
This class provides a simple means for IPC between two applications via a pipe.  


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

Inheritance diagram for KIO::Connection:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=63pt]{classKIO_1_1Connection__inherit__graph}
\end{center}
\end{figure}
Collaboration diagram for KIO::Connection:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=216pt]{classKIO_1_1Connection__coll__graph}
\end{center}
\end{figure}
\subsection*{Public Member Functions}
\begin{CompactItemize}
\item 
void {\bf init} ({\bf KSocket} $\ast$sock)\label{classKIO_1_1Connection_a2}

\item 
void {\bf init} (int fd\_\-in, int fd\_\-out)\label{classKIO_1_1Connection_a3}

\item 
void {\bf connect} ({\bf QObject} $\ast$receiver=0, const  char $\ast$member=0)\label{classKIO_1_1Connection_a4}

\item 
void {\bf close} ()\label{classKIO_1_1Connection_a5}

\item 
int {\bf fd\_\-from} () const \label{classKIO_1_1Connection_a6}

\item 
int {\bf fd\_\-to} () const \label{classKIO_1_1Connection_a7}

\item 
bool {\bf inited} () const \label{classKIO_1_1Connection_a8}

\item 
void {\bf send} (int cmd, const  {\bf QByte\-Array} \&arr={\bf QByte\-Array}())\label{classKIO_1_1Connection_a9}

\item 
bool {\bf sendnow} (int \_\-cmd, const  {\bf QByte\-Array} \&data)\label{classKIO_1_1Connection_a10}

\item 
int {\bf read} (int $\ast$\_\-cmd, {\bf QByte\-Array} \&)
\begin{CompactList}\small\item\em Receive data. \item\end{CompactList}\item 
void {\bf suspend} ()
\begin{CompactList}\small\item\em Don't handle incoming data until resumed. \item\end{CompactList}\item 
void {\bf resume} ()
\begin{CompactList}\small\item\em Resume handling of incoming data. \item\end{CompactList}\item 
bool {\bf suspended} () const 
\begin{CompactList}\small\item\em Returns status of connection. \item\end{CompactList}\end{CompactItemize}
\subsection*{Protected Slots}
\begin{CompactItemize}
\item 
void {\bf dequeue} ()\label{classKIO_1_1Connection_j0}

\end{CompactItemize}


\subsection{Detailed Description}
This class provides a simple means for IPC between two applications via a pipe. 

It handles a queue of commands to be sent which makes it possible to queue data before an actual connection has been established. 



Definition at line 46 of file connection.h.

\subsection{Member Function Documentation}
\index{KIO::Connection@{KIO::Connection}!read@{read}}
\index{read@{read}!KIO::Connection@{KIO::Connection}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int Connection::read (int $\ast$ {\em \_\-cmd}, {\bf QByte\-Array} \&)}\label{classKIO_1_1Connection_a11}


Receive data. 

\begin{Desc}
\item[Returns:]$>$=0 indicates the received data size upon success -1 indicates error\end{Desc}


Definition at line 197 of file connection.cpp.

Referenced by KIO::Slave\-Base::mime\-Type(), and KIO::Slave\-Base::wait\-For\-Answer().\index{KIO::Connection@{KIO::Connection}!suspend@{suspend}}
\index{suspend@{suspend}!KIO::Connection@{KIO::Connection}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void Connection::suspend ()}\label{classKIO_1_1Connection_a12}


Don't handle incoming data until resumed. 



Definition at line 64 of file connection.cpp.

References QSocket\-Notifier::set\-Enabled().\index{KIO::Connection@{KIO::Connection}!resume@{resume}}
\index{resume@{resume}!KIO::Connection@{KIO::Connection}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void Connection::resume ()}\label{classKIO_1_1Connection_a13}


Resume handling of incoming data. 



Definition at line 71 of file connection.cpp.

References QSocket\-Notifier::set\-Enabled().\index{KIO::Connection@{KIO::Connection}!suspended@{suspended}}
\index{suspended@{suspended}!KIO::Connection@{KIO::Connection}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool KIO::Connection::suspended () const\hspace{0.3cm}{\tt  [inline]}}\label{classKIO_1_1Connection_a14}


Returns status of connection. 



Definition at line 90 of file connection.h.

The documentation for this class was generated from the following files:\begin{CompactItemize}
\item 
connection.h\item 
connection.cpp\end{CompactItemize}
