\section{DCOPClient Class Reference}
\label{classDCOPClient}\index{DCOPClient@{DCOPClient}}
Inter-process communication and remote procedure calls for {\bf KDE} applications.  


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

Inheritance diagram for DCOPClient:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=53pt]{classDCOPClient__inherit__graph}
\end{center}
\end{figure}
Collaboration diagram for DCOPClient:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=53pt]{classDCOPClient__coll__graph}
\end{center}
\end{figure}
\subsection*{Signals}
\begin{CompactItemize}
\item 
void {\bf application\-Registered} (const {\bf QCString} \&app\-Id)
\item 
void {\bf application\-Removed} (const {\bf QCString} \&app\-Id)
\item 
void {\bf attach\-Failed} (const {\bf QString} \&msg)
\item 
void {\bf block\-User\-Input} (bool block)
\item 
void {\bf call\-Back} (int, const {\bf QCString} \&, const {\bf QByte\-Array} \&)\label{classDCOPClient_l4}

\end{CompactItemize}
\subsection*{Public Member Functions}
\begin{CompactItemize}
\item 
{\bf DCOPClient} ()
\item 
virtual {\bf $\sim$DCOPClient} ()
\item 
bool {\bf attach} ()
\item 
void {\bf bind\-To\-App} ()\label{classDCOPClient_a3}

\item 
bool {\bf detach} ()
\item 
bool {\bf is\-Attached} () const 
\item 
bool {\bf is\-Attached\-To\-Foreign\-Server} () const 
\item 
bool {\bf accept\-Calls} () const 
\item 
void {\bf set\-Accept\-Calls} (bool b)
\item 
bool {\bf qt\-Bridge\-Enabled} ()
\item 
void {\bf set\-Qt\-Bridge\-Enabled} (bool b)
\item 
{\bf QCString} {\bf register\-As} (const {\bf QCString} \&app\-Id, bool add\-PID=true)
\item 
bool {\bf is\-Registered} () const 
\item 
{\bf QCString} {\bf app\-Id} () const 
\item 
int {\bf socket} () const 
\item 
void {\bf suspend} ()
\item 
void {\bf resume} ()
\item 
bool {\bf is\-Suspended} () const 
\item 
bool {\bf send} (const {\bf QCString} \&rem\-App, const {\bf QCString} \&rem\-Obj, const {\bf QCString} \&rem\-Fun, const {\bf QByte\-Array} \&data)
\item 
bool {\bf send} (const {\bf QCString} \&rem\-App, const {\bf QCString} \&rem\-Obj, const {\bf QCString} \&rem\-Fun, const {\bf QString} \&data)
\item 
bool {\bf call} (const {\bf QCString} \&rem\-App, const {\bf QCString} \&rem\-Obj, const {\bf QCString} \&rem\-Fun, const {\bf QByte\-Array} \&data, {\bf QCString} \&reply\-Type, {\bf QByte\-Array} \&reply\-Data, bool use\-Event\-Loop, int timeout)
\item 
bool {\bf call} (const {\bf QCString} \&rem\-App, const {\bf QCString} \&rem\-Obj, const {\bf QCString} \&rem\-Fun, const {\bf QByte\-Array} \&data, {\bf QCString} \&reply\-Type, {\bf QByte\-Array} \&reply\-Data, bool use\-Event\-Loop=false)
\item 
int {\bf call\-Async} (const {\bf QCString} \&rem\-App, const {\bf QCString} \&rem\-Obj, const {\bf QCString} \&rem\-Fun, const {\bf QByte\-Array} \&data, {\bf QObject} $\ast$call\-Back\-Obj, const char $\ast$call\-Back\-Slot)
\item 
bool {\bf find\-Object} (const {\bf QCString} \&rem\-App, const {\bf QCString} \&rem\-Obj, const {\bf QCString} \&rem\-Fun, const {\bf QByte\-Array} \&data, {\bf QCString} \&found\-App, {\bf QCString} \&found\-Obj, bool use\-Event\-Loop, int timeout)
\item 
bool {\bf find\-Object} (const {\bf QCString} \&rem\-App, const {\bf QCString} \&rem\-Obj, const {\bf QCString} \&rem\-Fun, const {\bf QByte\-Array} \&data, {\bf QCString} \&found\-App, {\bf QCString} \&found\-Obj, bool use\-Event\-Loop=false)
\item 
void {\bf emit\-DCOPSignal} (const {\bf QCString} \&object, const {\bf QCString} \&signal, const {\bf QByte\-Array} \&data)
\item 
void {\bf emit\-DCOPSignal} (const {\bf QCString} \&signal, const {\bf QByte\-Array} \&data)\label{classDCOPClient_a26}

\item 
bool {\bf connect\-DCOPSignal} (const {\bf QCString} \&{\bf sender}, const {\bf QCString} \&sender\-Obj, const {\bf QCString} \&signal, const {\bf QCString} \&receiver\-Obj, const {\bf QCString} \&slot, bool Volatile)
\item 
bool {\bf connect\-DCOPSignal} (const {\bf QCString} \&{\bf sender}, const {\bf QCString} \&signal, const {\bf QCString} \&receiver\-Obj, const {\bf QCString} \&slot, bool Volatile) KDE\_\-DEPRECATED
\item 
bool {\bf disconnect\-DCOPSignal} (const {\bf QCString} \&{\bf sender}, const {\bf QCString} \&sender\-Obj, const {\bf QCString} \&signal, const {\bf QCString} \&receiver\-Obj, const {\bf QCString} \&slot)
\item 
bool {\bf disconnect\-DCOPSignal} (const {\bf QCString} \&{\bf sender}, const {\bf QCString} \&signal, const {\bf QCString} \&receiver\-Obj, const {\bf QCString} \&slot) KDE\_\-DEPRECATED
\item 
virtual bool {\bf process} (const {\bf QCString} \&fun, const {\bf QByte\-Array} \&data, {\bf QCString} \&reply\-Type, {\bf QByte\-Array} \&reply\-Data)
\item 
DCOPClient\-Transaction $\ast$ {\bf begin\-Transaction} ()
\item 
void {\bf end\-Transaction} (DCOPClient\-Transaction $\ast$t, {\bf QCString} \&reply\-Type, {\bf QByte\-Array} \&reply\-Data)
\item 
Q\_\-INT32 {\bf transaction\-Id} () const 
\item 
bool {\bf is\-Application\-Registered} (const {\bf QCString} \&rem\-App)
\item 
QCString\-List {\bf registered\-Applications} ()
\item 
QCString\-List {\bf remote\-Objects} (const {\bf QCString} \&rem\-App, bool $\ast$ok=0)
\item 
QCString\-List {\bf remote\-Interfaces} (const {\bf QCString} \&rem\-App, const {\bf QCString} \&rem\-Obj, bool $\ast$ok=0)
\item 
QCString\-List {\bf remote\-Functions} (const {\bf QCString} \&rem\-App, const {\bf QCString} \&rem\-Obj, bool $\ast$ok=0)
\item 
bool {\bf receive} (const {\bf QCString} \&app, const {\bf QCString} \&obj, const {\bf QCString} \&fun, const {\bf QByte\-Array} \&data, {\bf QCString} \&reply\-Type, {\bf QByte\-Array} \&reply\-Data)\label{classDCOPClient_a40}

\item 
bool {\bf find} (const {\bf QCString} \&app, const {\bf QCString} \&obj, const {\bf QCString} \&fun, const {\bf QByte\-Array} \&data, {\bf QCString} \&reply\-Type, {\bf QByte\-Array} \&reply\-Data)\label{classDCOPClient_a41}

\item 
{\bf QCString} {\bf sender\-Id} () const 
\item 
void {\bf set\-Default\-Object} (const {\bf QCString} \&obj\-Id)
\item 
{\bf QCString} {\bf default\-Object} () const 
\item 
void {\bf set\-Notifications} (bool enabled)
\item 
void {\bf set\-Daemon\-Mode} (bool daemon\-Mode)
\item 
void {\bf set\-Priority\-Call} (bool)\label{classDCOPClient_a47}

\item 
void {\bf handle\-Async\-Reply} (Reply\-Struct $\ast$reply\-Struct)\label{classDCOPClient_a48}

\end{CompactItemize}
\subsection*{Static Public Member Functions}
\begin{CompactItemize}
\item 
static void {\bf set\-Server\-Address} (const {\bf QCString} \&addr)
\item 
static {\bf QCString} {\bf normalize\-Function\-Signature} (const {\bf QCString} \&fun)
\item 
static {\bf DCOPClient} $\ast$ {\bf main\-Client} ()
\item 
static void {\bf set\-Main\-Client} ({\bf DCOPClient} $\ast$main\-Client)
\item 
static {\bf DCOPClient} $\ast$ {\bf find\-Local\-Client} (const {\bf QCString} \&\_\-app\-Id)
\item 
static void {\bf emergency\-Close} ()\label{classDCOPClient_e5}

\item 
static const char $\ast$ {\bf post\-Mortem\-Sender} ()\label{classDCOPClient_e6}

\item 
static const char $\ast$ {\bf post\-Mortem\-Object} ()\label{classDCOPClient_e7}

\item 
static const char $\ast$ {\bf post\-Mortem\-Function} ()\label{classDCOPClient_e8}

\item 
static {\bf QCString} {\bf dcop\-Server\-File} (const {\bf QCString} \&hostname=0)
\item 
static {\bf QCString} {\bf dcop\-Server\-File\-Old} (const {\bf QCString} \&hostname=0) KDE\_\-DEPRECATED
\item 
static {\bf QCString} {\bf iceauth\-Path} ()
\end{CompactItemize}
\subsection*{Protected Slots}
\begin{CompactItemize}
\item 
void {\bf process\-Socket\-Data} (int socknum)
\end{CompactItemize}
\subsection*{Protected Member Functions}
\begin{CompactItemize}
\item 
virtual void {\bf virtual\_\-hook} (int id, void $\ast$data)\label{classDCOPClient_b0}

\end{CompactItemize}
\subsection*{Related Functions}
(Note that these are not member functions.) \begin{CompactItemize}
\item 
Bool {\bf dcop\_\-attach} (void)
\item 
char $\ast$ {\bf dcop\_\-register} (const char $\ast$app\_\-name, Bool add\_\-pid)
\item 
Bool {\bf dcop\_\-detach} (void)
\item 
Bool {\bf dcop\_\-register\_\-callback} (const char $\ast$object\_\-id, dcop\_\-callback\_\-t callback)
\item 
Bool {\bf dcop\_\-send\_\-signal} (const char $\ast$receiving\_\-app, const char $\ast$object, const char $\ast$function, char $\ast$data, int data\_\-length)
\item 
Bool {\bf dcop\_\-call} (const char $\ast$app\_\-name, const char $\ast$remote\_\-app\_\-name, const char $\ast$remote\_\-object\_\-id, const char $\ast$remote\_\-function, const char $\ast$data, int data\_\-length, char $\ast$$\ast$reply\_\-type, char $\ast$$\ast$reply\_\-data, int $\ast$reply\_\-data\_\-length)
\end{CompactItemize}


\subsection{Detailed Description}
Inter-process communication and remote procedure calls for {\bf KDE} applications. 

This class provides IPC and RPC for {\bf KDE} applications. Usually you will not have to instantiate one yourself because {\bf KApplication} contains a method to return a pointer to a DCOPClient object which can be used for your whole application.

Before being able to send or receive any DCOP messages, you will have to attach your client object to the DCOP server, and then register your application with a specific name. See {\bf attach()}{\rm (p.\,\pageref{classDCOPClient_a2})} and {\bf register\-As()}{\rm (p.\,\pageref{classDCOPClient_a11})} for more information.

Data to be sent should be serialized into a {\bf QData\-Stream} which was initialized with the {\bf QByte\-Array} that you actually intend to send the data in. An example of how you might do this:



\footnotesize\begin{verbatim}   QByteArray data;
   QDataStream arg(data, IO_WriteOnly);
   arg << QString("This is text I am serializing");
   client->send("someApp", "someObject", "someFunction(QString)", data);
\end{verbatim}
\normalsize


\begin{Desc}
\item[See also:]{\bf KApplication::dcop\-Client()} \end{Desc}
\begin{Desc}
\item[Author:]Preston Brown $<${\tt pbrown@kde.org}$>$, Matthias Ettrich $<${\tt ettrich@kde.org}$>$ \end{Desc}




Definition at line 68 of file dcopclient.h.

\subsection{Constructor \& Destructor Documentation}
\index{DCOPClient@{DCOPClient}!DCOPClient@{DCOPClient}}
\index{DCOPClient@{DCOPClient}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}DCOPClient::DCOPClient ()}\label{classDCOPClient_a0}


Constructs a new DCOP client, but does not attach to any server. 



Definition at line 602 of file dcopclient.cpp.

References app\-Id(), QObject::connect(), main\-Client(), QObject::parent(), and set\-Main\-Client().\index{DCOPClient@{DCOPClient}!~DCOPClient@{$\sim$DCOPClient}}
\index{~DCOPClient@{$\sim$DCOPClient}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}DCOPClient::$\sim${\bf DCOPClient} ()\hspace{0.3cm}{\tt  [virtual]}}\label{classDCOPClient_a1}


Cleans up any open connections and dynamic data. 



Definition at line 629 of file dcopclient.cpp.

References detach(), main\-Client(), and set\-Main\-Client().

\subsection{Member Function Documentation}
\index{DCOPClient@{DCOPClient}!setServerAddress@{setServerAddress}}
\index{setServerAddress@{setServerAddress}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void DCOPClient::set\-Server\-Address (const {\bf QCString} \& {\em addr})\hspace{0.3cm}{\tt  [static]}}\label{classDCOPClient_e0}


Sets the address of a server to use upon attaching. 

If no server address is ever specified, attach will try its best to find the server anyway. \begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em addr}]the new address of the server \end{description}
\end{Desc}


Definition at line 667 of file dcopclient.cpp.\index{DCOPClient@{DCOPClient}!attach@{attach}}
\index{attach@{attach}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool DCOPClient::attach ()}\label{classDCOPClient_a2}


Attaches to the DCOP server. 

If the connection was already attached, the connection will be re-established with the current server address.

Naturally, only attached application can use DCOP services.

If a {\bf QApplication} object exists then client registers itself as QApplication::name() + \char`\"{}-\char`\"{} + $<$pid$>$. If no {\bf QApplication} object exists the client registers itself as \char`\"{}anonymous\char`\"{}.

If you want to register differently, you should use {\bf register\-As()}{\rm (p.\,\pageref{classDCOPClient_a11})} instead.

\begin{Desc}
\item[Returns:]true if attaching was successful. \end{Desc}


Definition at line 675 of file dcopclient.cpp.\index{DCOPClient@{DCOPClient}!detach@{detach}}
\index{detach@{detach}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool DCOPClient::detach ()}\label{classDCOPClient_a4}


Detaches from the DCOP server. 

\begin{Desc}
\item[Returns:]true if successful, false otherwise \end{Desc}


Definition at line 883 of file dcopclient.cpp.

Referenced by process\-Socket\-Data(), register\-As(), and $\sim$DCOPClient().\index{DCOPClient@{DCOPClient}!isAttached@{isAttached}}
\index{isAttached@{isAttached}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool DCOPClient::is\-Attached () const}\label{classDCOPClient_a5}


Returns whether or not the client is attached to the server. 

\begin{Desc}
\item[Returns:]true if attached, false if not \end{Desc}


Definition at line 910 of file dcopclient.cpp.

Referenced by accept\-Calls(), end\-Transaction(), is\-Attached\-To\-Foreign\-Server(), register\-As(), and send().\index{DCOPClient@{DCOPClient}!isAttachedToForeignServer@{isAttachedToForeignServer}}
\index{isAttachedToForeignServer@{isAttachedToForeignServer}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool DCOPClient::is\-Attached\-To\-Foreign\-Server () const}\label{classDCOPClient_a6}


Returns whether the client is attached to a server owned by another user. 

\begin{Desc}
\item[Returns:]true if attached to a foreign server, false if not \end{Desc}


Definition at line 922 of file dcopclient.cpp.

References is\-Attached().\index{DCOPClient@{DCOPClient}!acceptCalls@{acceptCalls}}
\index{acceptCalls@{acceptCalls}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool DCOPClient::accept\-Calls () const}\label{classDCOPClient_a7}


Returns whether the client handles incoming calls. 

\begin{Desc}
\item[Returns:]true if the client accepts calls \end{Desc}


Definition at line 927 of file dcopclient.cpp.

References is\-Attached().\index{DCOPClient@{DCOPClient}!setAcceptCalls@{setAcceptCalls}}
\index{setAcceptCalls@{setAcceptCalls}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void DCOPClient::set\-Accept\-Calls (bool {\em b})}\label{classDCOPClient_a8}


Specify whether the client should accept incoming calls. 

By default clients accept incoming calls, but not when connected to a foreign server. \begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em b}]true to accept calls, false to reject them \end{description}
\end{Desc}


Definition at line 932 of file dcopclient.cpp.\index{DCOPClient@{DCOPClient}!qtBridgeEnabled@{qtBridgeEnabled}}
\index{qtBridgeEnabled@{qtBridgeEnabled}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool DCOPClient::qt\-Bridge\-Enabled ()}\label{classDCOPClient_a9}


Returns whether the DCOP - {\bf Qt} bridge is enabled. 

By default the DCOP - {\bf Qt} bridge is enabled. \begin{Desc}
\item[Returns:]true if {\bf Qt} objects are accessible over DCOP \end{Desc}
\begin{Desc}
\item[Since:]3.0.2 \end{Desc}


Definition at line 938 of file dcopclient.cpp.\index{DCOPClient@{DCOPClient}!setQtBridgeEnabled@{setQtBridgeEnabled}}
\index{setQtBridgeEnabled@{setQtBridgeEnabled}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void DCOPClient::set\-Qt\-Bridge\-Enabled (bool {\em b})}\label{classDCOPClient_a10}


Specify whether {\bf Qt} objects of the application should be accessible via DCOP. 

By default the DCOP - {\bf Qt} bridge is enabled. \begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em b}]true to make {\bf Qt} objects accessible over DCOP \end{description}
\end{Desc}
\begin{Desc}
\item[Since:]3.0.2 \end{Desc}


Definition at line 943 of file dcopclient.cpp.\index{DCOPClient@{DCOPClient}!registerAs@{registerAs}}
\index{registerAs@{registerAs}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QCString} DCOPClient::register\-As (const {\bf QCString} \& {\em app\-Id}, bool {\em add\-PID} = {\tt true})}\label{classDCOPClient_a11}


Registers at the DCOP server. 

If the application was already registered, the registration will be re-done with the new app\-Id.

{\tt app\-Id} is a {\tt unique} application/program id that the server will use to associate requests with. If there is already an application registered with the same name, the server will add a number to the id to unify it. If {\tt add\-PID} is true, the PID of the current process will be added to id.

Registration is necessary if you want to allow other clients to talk to you. They can do so using your {\tt app\-Id} as first parameter for {\bf send()}{\rm (p.\,\pageref{classDCOPClient_a18})} or {\bf call()}{\rm (p.\,\pageref{classDCOPClient_a20})}. If you just want to talk to other clients, you do not need to register at the server. In that case {\bf attach()}{\rm (p.\,\pageref{classDCOPClient_a2})} is enough. It will implicitly register you as \char`\"{}anonymous\char`\"{}.

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em app\-Id}]the id of the application \item[{\em add\-PID}]true to add the process id \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The actual {\tt app\-Id} used for the registration or a null string if the registration wasn't successful. \end{Desc}


Definition at line 948 of file dcopclient.cpp.

References app\-Id(), call(), detach(), is\-Attached(), QCString::is\-Null(), is\-Registered(), and QCString::sprintf().\index{DCOPClient@{DCOPClient}!isRegistered@{isRegistered}}
\index{isRegistered@{isRegistered}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool DCOPClient::is\-Registered () const}\label{classDCOPClient_a12}


Returns whether or not the client is registered at the server. 

\begin{Desc}
\item[Returns:]true if registered at the server \end{Desc}


Definition at line 995 of file dcopclient.cpp.

Referenced by register\-As().\index{DCOPClient@{DCOPClient}!appId@{appId}}
\index{appId@{appId}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QCString} DCOPClient::app\-Id () const}\label{classDCOPClient_a13}


Returns the current app id or a null string if the application hasn't yet been registered. 

\begin{Desc}
\item[Returns:]the application id, or QString::null if not registered \end{Desc}


Definition at line 1001 of file dcopclient.cpp.

Referenced by DCOPClient(), and register\-As().\index{DCOPClient@{DCOPClient}!socket@{socket}}
\index{socket@{socket}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int DCOPClient::socket () const}\label{classDCOPClient_a14}


Returns the socket fd that is used for communication with the server. 

\begin{Desc}
\item[Returns:]The socket over which DCOP is communicating with the server. \end{Desc}


Definition at line 1007 of file dcopclient.cpp.\index{DCOPClient@{DCOPClient}!suspend@{suspend}}
\index{suspend@{suspend}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void DCOPClient::suspend ()}\label{classDCOPClient_a15}


Temporarily suspends processing of DCOP events. 

This can be useful if you need to show e.g. a dialog before your application is ready to accept DCOP requests. Normally the dialog would start an event loop and in this event loop DCOP requests will be handled.

Be aware that not responding to DCOP requests may cause other programs that want to communicate with your application, to hang. \begin{Desc}
\item[See also:]{\bf resume()}{\rm (p.\,\pageref{classDCOPClient_a16})} 

{\bf is\-Suspended()}{\rm (p.\,\pageref{classDCOPClient_a17})} \end{Desc}


Definition at line 697 of file dcopclient.cpp.\index{DCOPClient@{DCOPClient}!resume@{resume}}
\index{resume@{resume}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void DCOPClient::resume ()}\label{classDCOPClient_a16}


Resumes the processing of DCOP events. 

\begin{Desc}
\item[See also:]{\bf suspend()}{\rm (p.\,\pageref{classDCOPClient_a15})}. 

{\bf is\-Suspended()}{\rm (p.\,\pageref{classDCOPClient_a17})} \end{Desc}


Definition at line 703 of file dcopclient.cpp.\index{DCOPClient@{DCOPClient}!isSuspended@{isSuspended}}
\index{isSuspended@{isSuspended}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool DCOPClient::is\-Suspended () const}\label{classDCOPClient_a17}


Returns whether DCOP events are being processed. 

\begin{Desc}
\item[See also:]{\bf suspend()}{\rm (p.\,\pageref{classDCOPClient_a15})} 

{\bf resume()}{\rm (p.\,\pageref{classDCOPClient_a16})}. \end{Desc}
\begin{Desc}
\item[Since:]3.1 \end{Desc}


Definition at line 709 of file dcopclient.cpp.\index{DCOPClient@{DCOPClient}!send@{send}}
\index{send@{send}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool DCOPClient::send (const {\bf QCString} \& {\em rem\-App}, const {\bf QCString} \& {\em rem\-Obj}, const {\bf QCString} \& {\em rem\-Fun}, const {\bf QByte\-Array} \& {\em data})}\label{classDCOPClient_a18}


Sends a data block to the server. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em rem\-App}]The remote application id. \item[{\em rem\-Obj}]The name of the remote object. \item[{\em rem\-Fun}]The remote function in the specified object to call. \item[{\em data}]The data to provide to the remote function.\end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]Whether or not the server was able to accept the send. \end{Desc}


Definition at line 1056 of file dcopclient.cpp.

References find\-Local\-Client(), is\-Attached(), normalize\-Function\-Signature(), receive(), sender\-Id(), and transaction\-Id().

Referenced by emit\-DCOPSignal(), and send().\index{DCOPClient@{DCOPClient}!send@{send}}
\index{send@{send}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool DCOPClient::send (const {\bf QCString} \& {\em rem\-App}, const {\bf QCString} \& {\em rem\-Obj}, const {\bf QCString} \& {\em rem\-Fun}, const {\bf QString} \& {\em data})}\label{classDCOPClient_a19}


This function acts exactly the same as the above, but the data parameter can be specified as a {\bf QString} for convenience. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em rem\-App}]The remote application id. \item[{\em rem\-Obj}]The name of the remote object. \item[{\em rem\-Fun}]The remote function in the specified object to call. \item[{\em data}]The data to provide to the remote function.\end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]Whether or not the server was able to accept the send. \end{Desc}


Definition at line 1112 of file dcopclient.cpp.

References send().\index{DCOPClient@{DCOPClient}!call@{call}}
\index{call@{call}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool DCOPClient::call (const {\bf QCString} \& {\em rem\-App}, const {\bf QCString} \& {\em rem\-Obj}, const {\bf QCString} \& {\em rem\-Fun}, const {\bf QByte\-Array} \& {\em data}, {\bf QCString} \& {\em reply\-Type}, {\bf QByte\-Array} \& {\em reply\-Data}, bool {\em use\-Event\-Loop}, int {\em timeout})}\label{classDCOPClient_a20}


Performs a synchronous send and receive. 

The parameters are the same as for send, with the exception of another {\bf QByte\-Array} being provided for results to be (optionally) returned in.

A call blocks the application until the process receives the answer.

If {\tt use\-Event\-Loop} is true, a local event loop will be started after 1/10th of a second in order to keep the user interface updated (by processing paint events and such) until an answer is received.

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em rem\-App}]the remote application's id \item[{\em rem\-Obj}]the remote object id \item[{\em rem\-Fun}]the remote function id \item[{\em data}]the data to send \item[{\em reply\-Type}]the type of the reply will be written here \item[{\em reply\-Data}]the data of the reply will be written here \item[{\em use\-Event\-Loop}]if true the event loop will be started when the call blocks too long \item[{\em timeout}]timeout for the call in miliseconds, or -1 for no timeout \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]true if successful, false otherwise\end{Desc}
\begin{Desc}
\item[Since:]3.2\end{Desc}
\begin{Desc}
\item[See also:]{\bf send()}{\rm (p.\,\pageref{classDCOPClient_a18})} \end{Desc}


Definition at line 1746 of file dcopclient.cpp.

References QApplication::event\-Loop(), find\-Local\-Client(), is\-Local\-Transaction\-Finished(), receive(), sender\-Id(), and transaction\-Id().

Referenced by call(), connect\-DCOPSignal(), disconnect\-DCOPSignal(), is\-Application\-Registered(), register\-As(), registered\-Applications(), remote\-Functions(), remote\-Interfaces(), remote\-Objects(), set\-Daemon\-Mode(), and set\-Notifications().\index{DCOPClient@{DCOPClient}!call@{call}}
\index{call@{call}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool DCOPClient::call (const {\bf QCString} \& {\em rem\-App}, const {\bf QCString} \& {\em rem\-Obj}, const {\bf QCString} \& {\em rem\-Fun}, const {\bf QByte\-Array} \& {\em data}, {\bf QCString} \& {\em reply\-Type}, {\bf QByte\-Array} \& {\em reply\-Data}, bool {\em use\-Event\-Loop} = {\tt false})}\label{classDCOPClient_a21}


\begin{Desc}
\item[{\bf Deprecated}]\end{Desc}


Definition at line 1738 of file dcopclient.cpp.

References call().\index{DCOPClient@{DCOPClient}!callAsync@{callAsync}}
\index{callAsync@{callAsync}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}int DCOPClient::call\-Async (const {\bf QCString} \& {\em rem\-App}, const {\bf QCString} \& {\em rem\-Obj}, const {\bf QCString} \& {\em rem\-Fun}, const {\bf QByte\-Array} \& {\em data}, {\bf QObject} $\ast$ {\em call\-Back\-Obj}, const char $\ast$ {\em call\-Back\-Slot})}\label{classDCOPClient_a22}


Performs a asynchronous send with receive callback. 

The first four parameters are the same as for send.

{\tt call\-Back\-Obj} and {\tt call\-Back\-Slot} specify a call back slot that is called when an answer is received.

The slot should have the following signature: call\-Back\-Slot(int call\-Id, const {\bf QCString}\& reply\-Type, const {\bf QByte\-Array} \&reply\-Data);

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em rem\-App}]the remote application's id \item[{\em rem\-Obj}]the remote object id \item[{\em rem\-Fun}]the remote function id \item[{\em data}]the data to send \item[{\em call\-Back\-Obj}]object to call back \item[{\em call\-Back\-Slot}]slot to call back \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]0 on failure, on success a call\-Id $>$ 0 is returned that will be passed as first argument of the result call back\end{Desc}
\begin{Desc}
\item[See also:]{\bf send()}{\rm (p.\,\pageref{classDCOPClient_a18})} 

callback()\end{Desc}
\begin{Desc}
\item[Since:]3.2 \end{Desc}


Definition at line 1790 of file dcopclient.cpp.

References QCString::append(), and QTimer::single\-Shot().\index{DCOPClient@{DCOPClient}!findObject@{findObject}}
\index{findObject@{findObject}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool DCOPClient::find\-Object (const {\bf QCString} \& {\em rem\-App}, const {\bf QCString} \& {\em rem\-Obj}, const {\bf QCString} \& {\em rem\-Fun}, const {\bf QByte\-Array} \& {\em data}, {\bf QCString} \& {\em found\-App}, {\bf QCString} \& {\em found\-Obj}, bool {\em use\-Event\-Loop}, int {\em timeout})}\label{classDCOPClient_a23}


Searches for an object which matches a criteria. 

find\-Object calls {\tt rem\-Fun} in the applications and objects identified by {\tt rem\-App} and {\tt rem\-Obj} until {\tt rem\-Fun} returns true. The name of the application and object that returned true are returned in {\tt found\-App} and {\tt found\-Obj} respectively.

If {\tt rem\-Fun} is empty a default function is called in the object which always returns {\tt true}.

A find\-Object blocks the application until the process receives the answer.

If {\tt use\-Event\-Loop} is true, a local event loop will be started after 1/10th of a second in order to keep the user interface updated (by processing paint events and such) until an answer is received.

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em rem\-App}]The remote application id. \item[{\em rem\-Obj}]The name of the remote object. \item[{\em rem\-Fun}]The remote function in the specified object to call. This function should return a bool and is used as criteria. \item[{\em data}]The data to provide to the remote function. \item[{\em found\-App}]The remote application id that matched the criteria. \item[{\em found\-Obj}]The remote object that matched the criteria. \item[{\em use\-Event\-Loop}]if true the event loop will be started when the call blocks too long \item[{\em timeout}]timeout for the call in miliseconds, or -1 for no timeout \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]true is returned when an object was found for which {\tt rem\-Fun} returned true. If no such object is the function returns false.\end{Desc}
\begin{Desc}
\item[Since:]3.2\end{Desc}
\begin{Desc}
\item[See also:]{\bf send()}{\rm (p.\,\pageref{classDCOPClient_a18})} \end{Desc}


Definition at line 1129 of file dcopclient.cpp.

References DCOPRef::app(), QValue\-List::append(), QApplication::event\-Loop(), find(), find\-Local\-Client(), QCString::is\-Empty(), is\-Local\-Transaction\-Finished(), QCString::length(), registered\-Applications(), sender\-Id(), and transaction\-Id().

Referenced by find\-Object().\index{DCOPClient@{DCOPClient}!findObject@{findObject}}
\index{findObject@{findObject}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool DCOPClient::find\-Object (const {\bf QCString} \& {\em rem\-App}, const {\bf QCString} \& {\em rem\-Obj}, const {\bf QCString} \& {\em rem\-Fun}, const {\bf QByte\-Array} \& {\em data}, {\bf QCString} \& {\em found\-App}, {\bf QCString} \& {\em found\-Obj}, bool {\em use\-Event\-Loop} = {\tt false})}\label{classDCOPClient_a24}


\begin{Desc}
\item[{\bf Deprecated}]\end{Desc}


Definition at line 1121 of file dcopclient.cpp.

References find\-Object().\index{DCOPClient@{DCOPClient}!emitDCOPSignal@{emitDCOPSignal}}
\index{emitDCOPSignal@{emitDCOPSignal}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void DCOPClient::emit\-DCOPSignal (const {\bf QCString} \& {\em object}, const {\bf QCString} \& {\em signal}, const {\bf QByte\-Array} \& {\em data})}\label{classDCOPClient_a25}


Emits {\tt signal} as DCOP signal from object {\tt object} with {\tt data} as arguments. 



Definition at line 2151 of file dcopclient.cpp.

References normalize\-Function\-Signature(), and send().

Referenced by DCOPObject::emit\-DCOPSignal().\index{DCOPClient@{DCOPClient}!connectDCOPSignal@{connectDCOPSignal}}
\index{connectDCOPSignal@{connectDCOPSignal}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool DCOPClient::connect\-DCOPSignal (const {\bf QCString} \& {\em sender}, const {\bf QCString} \& {\em sender\-Obj}, const {\bf QCString} \& {\em signal}, const {\bf QCString} \& {\em receiver\-Obj}, const {\bf QCString} \& {\em slot}, bool {\em Volatile})}\label{classDCOPClient_a27}


Connects to a DCOP signal. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em sender}]the name of the client that emits the signal. When empty the signal will be passed from any client. \item[{\em sender\-Obj}]the name of the sending object that emits the signal. \item[{\em signal}]the name of the signal. The arguments should match with slot. \item[{\em receiver\-Obj}]The name of the object to call \item[{\em slot}]The name of the slot to call. Its arguments should match with signal. \item[{\em Volatile}]If true, the connection will not be reestablished when {\tt sender} unregisters and reregisters with DCOP. In this case the {\tt sender} must be registered when the connection is made. If false, the connection will be reestablished when {\tt sender} reregisters. In this case the connection can be made even if {\tt sender} is not registered at that time.\end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]false if a connection could not be established. This will be the case when \begin{itemize}
\item {\tt Volatile} is true and {\tt sender} does not exist. \item {\tt signal} and {\tt slot} do not have matching arguments. \end{itemize}
\end{Desc}


Definition at line 2164 of file dcopclient.cpp.

References call(), and normalize\-Function\-Signature().

Referenced by DCOPObject::connect\-DCOPSignal(), and connect\-DCOPSignal().\index{DCOPClient@{DCOPClient}!connectDCOPSignal@{connectDCOPSignal}}
\index{connectDCOPSignal@{connectDCOPSignal}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool DCOPClient::connect\-DCOPSignal (const {\bf QCString} \& {\em sender}, const {\bf QCString} \& {\em signal}, const {\bf QCString} \& {\em receiver\-Obj}, const {\bf QCString} \& {\em slot}, bool {\em Volatile})}\label{classDCOPClient_a28}


\begin{Desc}
\item[{\bf Deprecated}]For backwards compatibility \end{Desc}


Definition at line 2192 of file dcopclient.cpp.

References connect\-DCOPSignal().\index{DCOPClient@{DCOPClient}!disconnectDCOPSignal@{disconnectDCOPSignal}}
\index{disconnectDCOPSignal@{disconnectDCOPSignal}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool DCOPClient::disconnect\-DCOPSignal (const {\bf QCString} \& {\em sender}, const {\bf QCString} \& {\em sender\-Obj}, const {\bf QCString} \& {\em signal}, const {\bf QCString} \& {\em receiver\-Obj}, const {\bf QCString} \& {\em slot})}\label{classDCOPClient_a29}


Disconnects a DCOP signal. 

A special case is when both {\tt sender} \& {\tt signal} are empty. In this case all connections related to {\tt receiver\-Obj} in the current client are disconnected. (Both connections from as well as to this object!)

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em sender}]the name of the client that emits the signal. \item[{\em sender\-Obj}]the name of the object that emits the signal. If empty all objects will be disconnected. \item[{\em signal}]the name of the signal. The arguments should match with slot. \item[{\em receiver\-Obj}]The name of the object the signal is connected to. If empty all objects will be disconnected. \item[{\em slot}]The name of the slot the signal is connected to. If empty all slots will be disconnected. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]false if no connection(s) where removed. \end{Desc}


Definition at line 2199 of file dcopclient.cpp.

References call(), and normalize\-Function\-Signature().

Referenced by DCOPObject::disconnect\-DCOPSignal(), disconnect\-DCOPSignal(), DCOPObject::set\-Obj\-Id(), and DCOPObject::$\sim$DCOPObject().\index{DCOPClient@{DCOPClient}!disconnectDCOPSignal@{disconnectDCOPSignal}}
\index{disconnectDCOPSignal@{disconnectDCOPSignal}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool DCOPClient::disconnect\-DCOPSignal (const {\bf QCString} \& {\em sender}, const {\bf QCString} \& {\em signal}, const {\bf QCString} \& {\em receiver\-Obj}, const {\bf QCString} \& {\em slot})}\label{classDCOPClient_a30}


\begin{Desc}
\item[{\bf Deprecated}]For backwards compatibility \end{Desc}


Definition at line 2226 of file dcopclient.cpp.

References disconnect\-DCOPSignal().\index{DCOPClient@{DCOPClient}!process@{process}}
\index{process@{process}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool DCOPClient::process (const {\bf QCString} \& {\em fun}, const {\bf QByte\-Array} \& {\em data}, {\bf QCString} \& {\em reply\-Type}, {\bf QByte\-Array} \& {\em reply\-Data})\hspace{0.3cm}{\tt  [virtual]}}\label{classDCOPClient_a31}


Reimplement this function to handle app-wide function calls unassociated w/an object. 

Note that {\tt fun} is normalized. See {\bf normalize\-Function\-Signature()}{\rm (p.\,\pageref{classDCOPClient_e1})}.

If you do not want to reimplement this function for whatever reason, you can also use a default object or a {\bf DCOPObject\-Proxy}{\rm (p.\,\pageref{classDCOPObjectProxy})}.

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em fun}]the normalized function signature \item[{\em data}]the received data \item[{\em reply\-Type}]write the reply type in this string \item[{\em reply\-Data}]write the reply data in this array \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]true if successful, false otherwise \end{Desc}
\begin{Desc}
\item[See also:]{\bf set\-Default\-Object()}{\rm (p.\,\pageref{classDCOPClient_a43})} \end{Desc}


Definition at line 1225 of file dcopclient.cpp.\index{DCOPClient@{DCOPClient}!beginTransaction@{beginTransaction}}
\index{beginTransaction@{beginTransaction}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}DCOPClient\-Transaction $\ast$ DCOPClient::begin\-Transaction ()}\label{classDCOPClient_a32}


Delays the reply of the current function call until {\bf end\-Transaction()}{\rm (p.\,\pageref{classDCOPClient_a33})} is called. 

This allows a server to queue requests.

Note: Should be called from inside {\bf process()}{\rm (p.\,\pageref{classDCOPClient_a31})} only! \begin{Desc}
\item[See also:]{\bf end\-Transaction()}{\rm (p.\,\pageref{classDCOPClient_a33})} \end{Desc}


Definition at line 2067 of file dcopclient.cpp.

References QCString::append().\index{DCOPClient@{DCOPClient}!endTransaction@{endTransaction}}
\index{endTransaction@{endTransaction}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void DCOPClient::end\-Transaction (DCOPClient\-Transaction $\ast$ {\em t}, {\bf QCString} \& {\em reply\-Type}, {\bf QByte\-Array} \& {\em reply\-Data})}\label{classDCOPClient_a33}


Sends the delayed reply of a function call. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em t}]the transaction as received from {\bf begin\-Transaction()}{\rm (p.\,\pageref{classDCOPClient_a32})} \item[{\em reply\-Type}]write the reply type in this string \item[{\em reply\-Data}]write the reply data in this array \end{description}
\end{Desc}
\begin{Desc}
\item[See also:]{\bf begin\-Transaction()}{\rm (p.\,\pageref{classDCOPClient_a32})} \end{Desc}


Definition at line 2099 of file dcopclient.cpp.

References QCString::insert(), and is\-Attached().\index{DCOPClient@{DCOPClient}!transactionId@{transactionId}}
\index{transactionId@{transactionId}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}Q\_\-INT32 DCOPClient::transaction\-Id () const}\label{classDCOPClient_a34}


{\bf Test}{\rm (p.\,\pageref{classTest})} whether the current function call is delayed. 

Note: Should be called from inside {\bf process()}{\rm (p.\,\pageref{classDCOPClient_a31})} only! \begin{Desc}
\item[Returns:]The ID of the current transaction or 0 if no transaction is going on. \end{Desc}
\begin{Desc}
\item[See also:]{\bf process()}{\rm (p.\,\pageref{classDCOPClient_a31})} 

{\bf begin\-Transaction()}{\rm (p.\,\pageref{classDCOPClient_a32})} \end{Desc}


Definition at line 2090 of file dcopclient.cpp.

Referenced by call(), find\-Object(), and send().\index{DCOPClient@{DCOPClient}!isApplicationRegistered@{isApplicationRegistered}}
\index{isApplicationRegistered@{isApplicationRegistered}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}bool DCOPClient::is\-Application\-Registered (const {\bf QCString} \& {\em rem\-App})}\label{classDCOPClient_a35}


Checks whether {\tt rem\-App} is registered with the DCOP server. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em rem\-App}]the id of the remote application \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]true if the remote application is registered, otherwise {\tt false}. \end{Desc}


Definition at line 1231 of file dcopclient.cpp.

References call().\index{DCOPClient@{DCOPClient}!registeredApplications@{registeredApplications}}
\index{registeredApplications@{registeredApplications}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}QCString\-List DCOPClient::registered\-Applications ()}\label{classDCOPClient_a36}


Retrieves the list of all currently registered applications from dcopserver. 

\begin{Desc}
\item[Returns:]a list of all regietered applications \end{Desc}


Definition at line 1245 of file dcopclient.cpp.

References call().

Referenced by find\-Object().\index{DCOPClient@{DCOPClient}!remoteObjects@{remoteObjects}}
\index{remoteObjects@{remoteObjects}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}QCString\-List DCOPClient::remote\-Objects (const {\bf QCString} \& {\em rem\-App}, bool $\ast$ {\em ok} = {\tt 0})}\label{classDCOPClient_a37}


Retrieves the list of objects of the remote application {\tt rem\-App}. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em rem\-App}]he id of the application \item[{\em ok}]if not null, the function sets {\tt ok} to true if successful and false if an error occurred \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]the list of object ids \end{Desc}


Definition at line 1257 of file dcopclient.cpp.

References call().\index{DCOPClient@{DCOPClient}!remoteInterfaces@{remoteInterfaces}}
\index{remoteInterfaces@{remoteInterfaces}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}QCString\-List DCOPClient::remote\-Interfaces (const {\bf QCString} \& {\em rem\-App}, const {\bf QCString} \& {\em rem\-Obj}, bool $\ast$ {\em ok} = {\tt 0})}\label{classDCOPClient_a38}


Retrieves the list of interfaces of the remote object {\tt rem\-Obj} of application {\tt rem\-App}. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em rem\-App}]the id of the application \item[{\em rem\-Obj}]the id of the object \item[{\em ok}]if not null, the function sets {\tt ok} to true if successful and false if an error occurred \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]the list of interfaces \end{Desc}


Definition at line 1273 of file dcopclient.cpp.

References call().\index{DCOPClient@{DCOPClient}!remoteFunctions@{remoteFunctions}}
\index{remoteFunctions@{remoteFunctions}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}QCString\-List DCOPClient::remote\-Functions (const {\bf QCString} \& {\em rem\-App}, const {\bf QCString} \& {\em rem\-Obj}, bool $\ast$ {\em ok} = {\tt 0})}\label{classDCOPClient_a39}


Retrieves the list of functions of the remote object {\tt rem\-Obj} of application {\tt rem\-App}. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em rem\-App}]the id of the application \item[{\em rem\-Obj}]the id of the object \item[{\em ok}]if not null, the function sets {\tt ok} to true if successful and false if an error occurred \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]the list of function ids \end{Desc}


Definition at line 1289 of file dcopclient.cpp.

References call().\index{DCOPClient@{DCOPClient}!normalizeFunctionSignature@{normalizeFunctionSignature}}
\index{normalizeFunctionSignature@{normalizeFunctionSignature}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QCString} DCOPClient::normalize\-Function\-Signature (const {\bf QCString} \& {\em fun})\hspace{0.3cm}{\tt  [static]}}\label{classDCOPClient_e1}


Normalizes the function signature {\tt fun}. 

A normalized signature doesn't contain any unnecessary whitespace anymore. The remaining whitespace consists of single blanks only (0x20).

Example for a normalized signature: 

\footnotesize\begin{verbatim}   "someFunction(QString,int)"
\end{verbatim}
\normalsize


When using {\bf send()}{\rm (p.\,\pageref{classDCOPClient_a18})} or {\bf call()}{\rm (p.\,\pageref{classDCOPClient_a20})}, normalization is done automatically for you.

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em fun}]the function signature to normalize \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]the normalized function \end{Desc}


Definition at line 1022 of file dcopclient.cpp.

References QCString::copy(), QCString::is\-Empty(), and QCString::resize().

Referenced by connect\-DCOPSignal(), disconnect\-DCOPSignal(), emit\-DCOPSignal(), and send().\index{DCOPClient@{DCOPClient}!senderId@{senderId}}
\index{senderId@{senderId}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QCString} DCOPClient::sender\-Id () const}\label{classDCOPClient_a42}


Returns the app\-Id of the last application that talked to us. 

\begin{Desc}
\item[Returns:]the application id of the last application that send a message to this client \end{Desc}


Definition at line 1050 of file dcopclient.cpp.

Referenced by call(), find\-Object(), and send().\index{DCOPClient@{DCOPClient}!setDefaultObject@{setDefaultObject}}
\index{setDefaultObject@{setDefaultObject}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void DCOPClient::set\-Default\-Object (const {\bf QCString} \& {\em obj\-Id})}\label{classDCOPClient_a43}


Installs object {\tt obj\-Id} as application-wide default object. 

All app-wide messages that have not been processed by the dcopclient will be send further to {\tt obj\-Id}. \begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em obj\-Id}]the id of the new default object \end{description}
\end{Desc}


Definition at line 2041 of file dcopclient.cpp.\index{DCOPClient@{DCOPClient}!defaultObject@{defaultObject}}
\index{defaultObject@{defaultObject}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QCString} DCOPClient::default\-Object () const}\label{classDCOPClient_a44}


Returns the current default object or an empty string if no object is installed as default object. 

A default object receives application-wide messages that have not been processed by the DCOPClient itself. \begin{Desc}
\item[Returns:]the id of the new default object \end{Desc}


Definition at line 2047 of file dcopclient.cpp.\index{DCOPClient@{DCOPClient}!setNotifications@{setNotifications}}
\index{setNotifications@{setNotifications}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void DCOPClient::set\-Notifications (bool {\em enabled})}\label{classDCOPClient_a45}


Enables / disables the {\bf application\-Registered()}{\rm (p.\,\pageref{classDCOPClient_l0})} / {\bf application\-Removed()}{\rm (p.\,\pageref{classDCOPClient_l1})} signals. 

Note that a counter is maintained about how often this method was called. If this method is called twice with {\tt enabled} set to true, notifications will be enabled until it was called with {\tt enabled} set to false as often.

They are disabled by default. \begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em enabled}]true to enable notifications, false to disable \end{description}
\end{Desc}


Definition at line 1305 of file dcopclient.cpp.

References call().\index{DCOPClient@{DCOPClient}!setDaemonMode@{setDaemonMode}}
\index{setDaemonMode@{setDaemonMode}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void DCOPClient::set\-Daemon\-Mode (bool {\em daemon\-Mode})}\label{classDCOPClient_a46}


Tells the dcopserver to treat the client as daemon client, not as regular client. 

If the number of regular clients drops down to zero, the dcopserver will emit a {\bf KDE} termination signal after 10 seconds. \begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em daemon\-Mode}]true to enable daemon mode, false to disable \end{description}
\end{Desc}


Definition at line 1317 of file dcopclient.cpp.

References call().\index{DCOPClient@{DCOPClient}!mainClient@{mainClient}}
\index{mainClient@{mainClient}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf DCOPClient} $\ast$ DCOPClient::main\-Client ()\hspace{0.3cm}{\tt  [static]}}\label{classDCOPClient_e2}


Returns the application's main dcop client. 

The main client can be used by objects that do not have any specific access to a dcop client. In {\bf KDE} applications, the main client usually is the same as {\bf KApplication::dcop\-Client()}. \begin{Desc}
\item[Returns:]the application's main dcop client \end{Desc}


Definition at line 591 of file dcopclient.cpp.

Referenced by DCOPObject::connect\-DCOPSignal(), DCOPStub::dcop\-Client(), DCOPRef::dcop\-Client(), DCOPClient(), DCOPObject::disconnect\-DCOPSignal(), DCOPObject::emit\-DCOPSignal(), DCOPObject::set\-Obj\-Id(), $\sim$DCOPClient(), and DCOPObject::$\sim$DCOPObject().\index{DCOPClient@{DCOPClient}!setMainClient@{setMainClient}}
\index{setMainClient@{setMainClient}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void DCOPClient::set\-Main\-Client ({\bf DCOPClient} $\ast$ {\em main\-Client})\hspace{0.3cm}{\tt  [static]}}\label{classDCOPClient_e3}


Sets the application's main dcop client. 

The main client can be used by objects that do not have any specific access to a dcop client. In {\bf KDE} applications, the main client usually is the same as {\bf KApplication::dcop\-Client()}. \begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em main\-Client}]the new main dcop client \end{description}
\end{Desc}


Definition at line 596 of file dcopclient.cpp.

Referenced by DCOPClient(), and $\sim$DCOPClient().\index{DCOPClient@{DCOPClient}!findLocalClient@{findLocalClient}}
\index{findLocalClient@{findLocalClient}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf DCOPClient} $\ast$ DCOPClient::find\-Local\-Client (const {\bf QCString} \& {\em \_\-app\-Id})\hspace{0.3cm}{\tt  [static]}}\label{classDCOPClient_e4}


Look for the given client only in this process. 

This can be used to check whether a given client (by name) is running in the same process or in another one. 

Definition at line 98 of file dcopclient.cpp.

References QAscii\-Dict::find().

Referenced by call(), find\-Object(), and send().\index{DCOPClient@{DCOPClient}!dcopServerFile@{dcopServerFile}}
\index{dcopServerFile@{dcopServerFile}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QCString} DCOPClient::dcop\-Server\-File (const {\bf QCString} \& {\em hostname} = {\tt 0})\hspace{0.3cm}{\tt  [static]}}\label{classDCOPClient_e9}


File with information how to reach the dcopserver. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em hostname}]Hostname to use, if empty current hostname of the system is used. \end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]Filename that contains information how to contact the DCOPserver. \end{Desc}


Definition at line 300 of file dcopclient.cpp.\index{DCOPClient@{DCOPClient}!dcopServerFileOld@{dcopServerFileOld}}
\index{dcopServerFileOld@{dcopServerFileOld}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QCString} DCOPClient::dcop\-Server\-File\-Old (const {\bf QCString} \& {\em hostname} = {\tt 0})\hspace{0.3cm}{\tt  [static]}}\label{classDCOPClient_e10}


\begin{Desc}
\item[{\bf Deprecated}]For backwards compatibility with {\bf KDE} 2.x // KDE4 remove \end{Desc}


Definition at line 307 of file dcopclient.cpp.\index{DCOPClient@{DCOPClient}!iceauthPath@{iceauthPath}}
\index{iceauthPath@{iceauthPath}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf QCString} DCOPClient::iceauth\-Path ()\hspace{0.3cm}{\tt  [static]}}\label{classDCOPClient_e11}


Return the path of iceauth or an empty string if not found. 



Definition at line 223 of file dcopclient.cpp.

References QCString::is\-Empty(), and QCString::is\-Null().\index{DCOPClient@{DCOPClient}!applicationRegistered@{applicationRegistered}}
\index{applicationRegistered@{applicationRegistered}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void DCOPClient::application\-Registered (const {\bf QCString} \& {\em app\-Id})\hspace{0.3cm}{\tt  [signal]}}\label{classDCOPClient_l0}


Indicates that the application {\tt app\-Id} has been registered with the server we are attached to. 

You need to call {\bf set\-Notifications()}{\rm (p.\,\pageref{classDCOPClient_a45})} first, to tell the DCOP server that you want to get these events. \begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em app\-Id}]the id of the new application \end{description}
\end{Desc}
\index{DCOPClient@{DCOPClient}!applicationRemoved@{applicationRemoved}}
\index{applicationRemoved@{applicationRemoved}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void DCOPClient::application\-Removed (const {\bf QCString} \& {\em app\-Id})\hspace{0.3cm}{\tt  [signal]}}\label{classDCOPClient_l1}


Indicates that the formerly registered application {\tt app\-Id} has been removed. 

You need to call {\bf set\-Notifications()}{\rm (p.\,\pageref{classDCOPClient_a45})} first, to tell the DCOP server that you want to get these events. \begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em app\-Id}]the id of the removed application \end{description}
\end{Desc}
\index{DCOPClient@{DCOPClient}!attachFailed@{attachFailed}}
\index{attachFailed@{attachFailed}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void DCOPClient::attach\-Failed (const {\bf QString} \& {\em msg})\hspace{0.3cm}{\tt  [signal]}}\label{classDCOPClient_l2}


Indicates that the process of establishing DCOP communications failed in some manner. 

Usually attached to a dialog box or some other visual aid. \begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em msg}]the message tha contains further information \end{description}
\end{Desc}
\index{DCOPClient@{DCOPClient}!blockUserInput@{blockUserInput}}
\index{blockUserInput@{blockUserInput}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void DCOPClient::block\-User\-Input (bool {\em block})\hspace{0.3cm}{\tt  [signal]}}\label{classDCOPClient_l3}


Indicates that user input shall be blocked or released, depending on the argument. 

The signal is emitted whenever the client has to wait too long (i.e. more than 1/10 of a second) for an answer to a synchronous call. In that case, it will enter a local event loop to keep the GUI updated until finally an answer arrives.

In {\bf KDE}, the {\bf KApplication} object connects to this signal to be able to block any user input (i.e. mouse and key events) while we are waiting for an answer. If we did not do this, the application might end up in an illegal state, as a keyboard shortcut or a mouse action might cause another dcop call to be issued. \begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em block}]true to block user input, false otherwise \end{description}
\end{Desc}
\index{DCOPClient@{DCOPClient}!processSocketData@{processSocketData}}
\index{processSocketData@{processSocketData}!DCOPClient@{DCOPClient}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void DCOPClient::process\-Socket\-Data (int {\em socknum})\hspace{0.3cm}{\tt  [protected, slot]}}\label{classDCOPClient_j0}


Process data from the socket. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em socknum}]the fd of the socket \end{description}
\end{Desc}


Definition at line 2005 of file dcopclient.cpp.

References detach().

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