stub.h00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013 #ifndef __Stub_h_Included__
00014 #define __Stub_h_Included__
00015
00016 #include <qcstring.h>
00017 #include <qvaluelist.h>
00018
00019 #include "process.h"
00020 #include "kcookie.h"
00021
00022 #include <kdelibs_export.h>
00023
00024 typedef QValueList<QCString> QCStringList;
00025
00032 class KDESU_EXPORT StubProcess: public PtyProcess
00033 {
00034 public:
00035 StubProcess();
00036 ~StubProcess();
00037
00041 void setDcopTransport(const QCString &dcopTransport)
00042 { m_pCookie->setDcopTransport(dcopTransport); }
00043
00047 void setCommand(const QCString &command) { m_Command = command; }
00048
00052 void setUser(const QCString &user) { m_User = user; }
00053
00057 void setXOnly(bool xonly) { m_bXOnly = xonly; }
00058
00062 void setDCOPForwarding(bool dcopForwarding) { m_bDCOPForwarding = dcopForwarding; }
00063
00069 void setPriority(int prio);
00070
00075 enum Scheduler { SchedNormal, SchedRealtime };
00076
00080 void setScheduler(int sched) { m_Scheduler = sched; }
00081
00082 protected:
00083
00087 int ConverseStub(int check);
00088
00093
00094 void notifyTaskbar(const QString &suffix);
00095
00100 virtual QCString display() { return m_pCookie->display(); }
00101 #ifdef Q_WS_X11
00102
00105 virtual QCString displayAuth() { return m_pCookie->displayAuth(); }
00106 #endif
00107
00110 virtual QCString dcopServer() { return m_pCookie->dcopServer(); }
00114 virtual QCString dcopAuth() { return m_pCookie->dcopAuth(); }
00118 virtual QCString iceAuth() { return m_pCookie->iceAuth(); }
00119
00120 bool m_bXOnly;
00121 bool m_bDCOPForwarding;
00122 int m_Priority;
00123 int m_Scheduler;
00124 QCString m_dcopTransport;
00125 QCString m_Command;
00126 QCString m_User;
00127 KCookie *m_pCookie;
00128
00129 private:
00130 QCString commaSeparatedList(QCStringList);
00131
00132 protected:
00133 virtual void virtual_hook( int id, void* data );
00134 private:
00135 class StubProcessPrivate;
00136 StubProcessPrivate *d;
00137 };
00138
00139 #endif // __Stub_h_Included__
|