diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:48:06 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:48:06 +0000 |
commit | 47c8a359c5276062c4bc17f0e82410f29081b502 (patch) | |
tree | 2d54a5f60a5b74067632f9ef6df58c2bc38155e6 /kopete/protocols/jabber/libiris/iris/include | |
parent | 6f82532777a35e0e60bbd2b290b2e93e646f349b (diff) | |
download | tdenetwork-47c8a359c5276062c4bc17f0e82410f29081b502.tar.gz tdenetwork-47c8a359c5276062c4bc17f0e82410f29081b502.zip |
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdenetwork@1157648 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kopete/protocols/jabber/libiris/iris/include')
-rw-r--r-- | kopete/protocols/jabber/libiris/iris/include/im.h | 388 | ||||
-rw-r--r-- | kopete/protocols/jabber/libiris/iris/include/xmpp.h | 224 |
2 files changed, 306 insertions, 306 deletions
diff --git a/kopete/protocols/jabber/libiris/iris/include/im.h b/kopete/protocols/jabber/libiris/iris/include/im.h index 170338fc..f4905057 100644 --- a/kopete/protocols/jabber/libiris/iris/include/im.h +++ b/kopete/protocols/jabber/libiris/iris/include/im.h @@ -21,8 +21,8 @@ #ifndef XMPP_IM_H #define XMPP_IM_H -#include<qdatetime.h> -#include<qvaluelist.h> +#include<tqdatetime.h> +#include<tqvaluelist.h> #include"xmpp.h" namespace XMPP @@ -30,24 +30,24 @@ namespace XMPP class Url { public: - Url(const QString &url="", const QString &desc=""); + Url(const TQString &url="", const TQString &desc=""); Url(const Url &); Url & operator=(const Url &); ~Url(); - QString url() const; - QString desc() const; + TQString url() const; + TQString desc() const; - void setUrl(const QString &); - void setDesc(const QString &); + void setUrl(const TQString &); + void setDesc(const TQString &); private: class Private; Private *d; }; - typedef QValueList<Url> UrlList; - typedef QMap<QString, QString> StringMap; + typedef TQValueList<Url> UrlList; + typedef TQMap<TQString, TQString> StringMap; typedef enum { OfflineEvent, DeliveredEvent, DisplayedEvent, ComposingEvent, CancelEvent, InactiveEvent, GoneEvent } MsgEvent; @@ -61,29 +61,29 @@ namespace XMPP Jid to() const; Jid from() const; - QString id() const; - QString type() const; - QString lang() const; - QString subject(const QString &lang="") const; - QString body(const QString &lang="") const; - QString xHTMLBody(const QString &lang="") const; - QString thread() const; + TQString id() const; + TQString type() const; + TQString lang() const; + TQString subject(const TQString &lang="") const; + TQString body(const TQString &lang="") const; + TQString xHTMLBody(const TQString &lang="") const; + TQString thread() const; Stanza::Error error() const; void setTo(const Jid &j); void setFrom(const Jid &j); - void setId(const QString &s); - void setType(const QString &s); - void setLang(const QString &s); - void setSubject(const QString &s, const QString &lang=""); - void setBody(const QString &s, const QString &lang=""); - void setXHTMLBody(const QString &s, const QString &lang="", const QString &attr = ""); - void setThread(const QString &s); + void setId(const TQString &s); + void setType(const TQString &s); + void setLang(const TQString &s); + void setSubject(const TQString &s, const TQString &lang=""); + void setBody(const TQString &s, const TQString &lang=""); + void setXHTMLBody(const TQString &s, const TQString &lang="", const TQString &attr = ""); + void setThread(const TQString &s); void setError(const Stanza::Error &err); // JEP-0091 - QDateTime timeStamp() const; - void setTimeStamp(const QDateTime &ts); + TQDateTime timeStamp() const; + void setTimeStamp(const TQDateTime &ts); // JEP-0066 UrlList urlList() const; @@ -92,19 +92,19 @@ namespace XMPP void setUrlList(const UrlList &list); // JEP-0022 - QString eventId() const; - void setEventId(const QString& id); + TQString eventId() const; + void setEventId(const TQString& id); bool containsEvents() const; bool containsEvent(MsgEvent e) const; void addEvent(MsgEvent e); // JEP-0027 - QString xencrypted() const; - void setXEncrypted(const QString &s); + TQString xencrypted() const; + void setXEncrypted(const TQString &s); // Obsolete invitation - QString invite() const; - void setInvite(const QString &s); + TQString invite() const; + void setInvite(const TQString &s); // for compatibility. delete me later bool spooled() const; @@ -129,8 +129,8 @@ namespace XMPP int type() const; - QString toString() const; - bool fromString(const QString &); + TQString toString() const; + bool fromString(const TQString &); private: SubType value; @@ -139,56 +139,56 @@ namespace XMPP class Status { public: - Status(const QString &show="", const QString &status="", int priority=0, bool available=true); + Status(const TQString &show="", const TQString &status="", int priority=0, bool available=true); ~Status(); int priority() const; - const QString & show() const; - const QString & status() const; - QDateTime timeStamp() const; - const QString & keyID() const; + const TQString & show() const; + const TQString & status() const; + TQDateTime timeStamp() const; + const TQString & keyID() const; bool isAvailable() const; bool isAway() const; bool isInvisible() const; bool hasError() const; int errorCode() const; - const QString & errorString() const; + const TQString & errorString() const; - const QString & xsigned() const; - const QString & songTitle() const; - const QString & capsNode() const; - const QString & capsVersion() const; - const QString & capsExt() const; + const TQString & xsigned() const; + const TQString & songTitle() const; + const TQString & capsNode() const; + const TQString & capsVersion() const; + const TQString & capsExt() const; void setPriority(int); - void setShow(const QString &); - void setStatus(const QString &); - void setTimeStamp(const QDateTime &); - void setKeyID(const QString &); + void setShow(const TQString &); + void setStatus(const TQString &); + void setTimeStamp(const TQDateTime &); + void setKeyID(const TQString &); void setIsAvailable(bool); void setIsInvisible(bool); - void setError(int, const QString &); - void setCapsNode(const QString&); - void setCapsVersion(const QString&); - void setCapsExt(const QString&); + void setError(int, const TQString &); + void setCapsNode(const TQString&); + void setCapsVersion(const TQString&); + void setCapsExt(const TQString&); - void setXSigned(const QString &); - void setSongTitle(const QString &); + void setXSigned(const TQString &); + void setSongTitle(const TQString &); private: int v_priority; - QString v_show, v_status, v_key; - QDateTime v_timeStamp; + TQString v_show, v_status, v_key; + TQDateTime v_timeStamp; bool v_isAvailable; bool v_isInvisible; - QString v_xsigned; + TQString v_xsigned; // gabber song extension - QString v_songTitle; - QString v_capsNode, v_capsVersion, v_capsExt; + TQString v_songTitle; + TQString v_capsNode, v_capsVersion, v_capsExt; int ecode; - QString estr; + TQString estr; class Private; Private *d; @@ -197,33 +197,33 @@ namespace XMPP class Resource { public: - Resource(const QString &name="", const Status &s=Status()); + Resource(const TQString &name="", const Status &s=Status()); ~Resource(); - const QString & name() const; + const TQString & name() const; int priority() const; const Status & status() const; - void setName(const QString &); + void setName(const TQString &); void setStatus(const Status &); private: - QString v_name; + TQString v_name; Status v_status; class ResourcePrivate *d; }; - class ResourceList : public QValueList<Resource> + class ResourceList : public TQValueList<Resource> { public: ResourceList(); ~ResourceList(); - ResourceList::Iterator find(const QString &); + ResourceList::Iterator find(const TQString &); ResourceList::Iterator priority(); - ResourceList::ConstIterator find(const QString &) const; + ResourceList::ConstIterator find(const TQString &) const; ResourceList::ConstIterator priority() const; private: @@ -237,37 +237,37 @@ namespace XMPP virtual ~RosterItem(); const Jid & jid() const; - const QString & name() const; - const QStringList & groups() const; + const TQString & name() const; + const TQStringList & groups() const; const Subscription & subscription() const; - const QString & ask() const; + const TQString & ask() const; bool isPush() const; - bool inGroup(const QString &) const; + bool inGroup(const TQString &) const; virtual void setJid(const Jid &); - void setName(const QString &); - void setGroups(const QStringList &); + void setName(const TQString &); + void setGroups(const TQStringList &); void setSubscription(const Subscription &); - void setAsk(const QString &); + void setAsk(const TQString &); void setIsPush(bool); - bool addGroup(const QString &); - bool removeGroup(const QString &); + bool addGroup(const TQString &); + bool removeGroup(const TQString &); - QDomElement toXml(QDomDocument *) const; - bool fromXml(const QDomElement &); + TQDomElement toXml(TQDomDocument *) const; + bool fromXml(const TQDomElement &); private: Jid v_jid; - QString v_name; - QStringList v_groups; + TQString v_name; + TQStringList v_groups; Subscription v_subscription; - QString v_ask; + TQString v_ask; bool v_push; class RosterItemPrivate *d; }; - class Roster : public QValueList<RosterItem> + class Roster : public TQValueList<RosterItem> { public: Roster(); @@ -284,12 +284,12 @@ namespace XMPP { public: Features(); - Features(const QStringList &); - Features(const QString &); + Features(const TQStringList &); + Features(const TQString &); ~Features(); - QStringList list() const; // actual featurelist - void setList(const QStringList &); + TQStringList list() const; // actual featurelist + void setList(const TQStringList &); // features bool canRegister() const; @@ -317,19 +317,19 @@ namespace XMPP }; // useful functions - bool test(const QStringList &) const; + bool test(const TQStringList &) const; - QString name() const; - static QString name(long id); - static QString name(const QString &feature); + TQString name() const; + static TQString name(long id); + static TQString name(const TQString &feature); long id() const; - static long id(const QString &feature); - static QString feature(long id); + static long id(const TQString &feature); + static TQString feature(long id); class FeatureName; private: - QStringList _list; + TQStringList _list; }; class AgentItem @@ -338,24 +338,24 @@ namespace XMPP AgentItem() { } const Jid & jid() const { return v_jid; } - const QString & name() const { return v_name; } - const QString & category() const { return v_category; } - const QString & type() const { return v_type; } + const TQString & name() const { return v_name; } + const TQString & category() const { return v_category; } + const TQString & type() const { return v_type; } const Features & features() const { return v_features; } void setJid(const Jid &j) { v_jid = j; } - void setName(const QString &n) { v_name = n; } - void setCategory(const QString &c) { v_category = c; } - void setType(const QString &t) { v_type = t; } + void setName(const TQString &n) { v_name = n; } + void setCategory(const TQString &c) { v_category = c; } + void setType(const TQString &t) { v_type = t; } void setFeatures(const Features &f) { v_features = f; } private: Jid v_jid; - QString v_name, v_category, v_type; + TQString v_name, v_category, v_type; Features v_features; }; - typedef QValueList<AgentItem> AgentList; + typedef TQValueList<AgentItem> AgentList; class DiscoItem { @@ -364,12 +364,12 @@ namespace XMPP ~DiscoItem(); const Jid &jid() const; - const QString &node() const; - const QString &name() const; + const TQString &node() const; + const TQString &name() const; void setJid(const Jid &); - void setName(const QString &); - void setNode(const QString &); + void setName(const TQString &); + void setNode(const TQString &); enum Action { None = 0, @@ -385,19 +385,19 @@ namespace XMPP struct Identity { - QString category; - QString name; - QString type; + TQString category; + TQString name; + TQString type; }; - typedef QValueList<Identity> Identities; + typedef TQValueList<Identity> Identities; const Identities &identities() const; void setIdentities(const Identities &); // some useful helper functions - static Action string2action(QString s); - static QString action2string(Action a); + static Action string2action(TQString s); + static TQString action2string(Action a); DiscoItem & operator= (const DiscoItem &); DiscoItem(const DiscoItem &); @@ -411,51 +411,51 @@ namespace XMPP Private *d; }; - typedef QValueList<DiscoItem> DiscoList; + typedef TQValueList<DiscoItem> DiscoList; class FormField { public: enum { username, nick, password, name, first, last, email, address, city, state, zip, phone, url, date, misc }; - FormField(const QString &type="", const QString &value=""); + FormField(const TQString &type="", const TQString &value=""); ~FormField(); int type() const; - QString fieldName() const; - QString realName() const; + TQString fieldName() const; + TQString realName() const; bool isSecret() const; - const QString & value() const; + const TQString & value() const; void setType(int); - bool setType(const QString &); - void setValue(const QString &); + bool setType(const TQString &); + void setValue(const TQString &); private: - int tagNameToType(const QString &) const; - QString typeToTagName(int) const; + int tagNameToType(const TQString &) const; + TQString typeToTagName(int) const; int v_type; - QString v_value; + TQString v_value; class Private; Private *d; }; - class Form : public QValueList<FormField> + class Form : public TQValueList<FormField> { public: Form(const Jid &j=""); ~Form(); Jid jid() const; - QString instructions() const; - QString key() const; + TQString instructions() const; + TQString key() const; void setJid(const Jid &); - void setInstructions(const QString &); - void setKey(const QString &); + void setInstructions(const TQString &); + void setKey(const TQString &); private: Jid v_jid; - QString v_instructions, v_key; + TQString v_instructions, v_key; class Private; Private *d; @@ -468,20 +468,20 @@ namespace XMPP ~SearchResult(); const Jid & jid() const; - const QString & nick() const; - const QString & first() const; - const QString & last() const; - const QString & email() const; + const TQString & nick() const; + const TQString & first() const; + const TQString & last() const; + const TQString & email() const; void setJid(const Jid &); - void setNick(const QString &); - void setFirst(const QString &); - void setLast(const QString &); - void setEmail(const QString &); + void setNick(const TQString &); + void setFirst(const TQString &); + void setLast(const TQString &); + void setEmail(const TQString &); private: Jid v_jid; - QString v_nick, v_first, v_last, v_email; + TQString v_nick, v_first, v_last, v_email; }; class Client; @@ -503,15 +503,15 @@ namespace XMPP Task *parent() const; Client *client() const; - QDomDocument *doc() const; - QString id() const; + TQDomDocument *doc() const; + TQString id() const; bool success() const; int statusCode() const; - const QString & statusString() const; + const TQString & statusString() const; void go(bool autoDelete=false); - virtual bool take(const QDomElement &); + virtual bool take(const TQDomElement &); void safeDelete(); signals: @@ -520,13 +520,13 @@ namespace XMPP protected: virtual void onGo(); virtual void onDisconnect(); - void send(const QDomElement &); - void setSuccess(int code=0, const QString &str=""); - void setError(const QDomElement &); - void setError(int code=0, const QString &str=""); + void send(const TQDomElement &); + void setSuccess(int code=0, const TQString &str=""); + void setError(const TQDomElement &); + void setError(int code=0, const TQString &str=""); void debug(const char *, ...); - void debug(const QString &); - bool iqVerify(const QDomElement &x, const Jid &to, const QString &id, const QString &xmlns=""); + void debug(const TQString &); + bool iqVerify(const TQDomElement &x, const Jid &to, const TQString &id, const TQString &xmlns=""); private slots: void clientDisconnected(); @@ -544,60 +544,60 @@ namespace XMPP Q_OBJECT public: - Client(QObject *parent=0); + Client(TQObject *parent=0); ~Client(); bool isActive() const; void connectToServer(ClientStream *s, const Jid &j, bool auth=true); - void start(const QString &host, const QString &user, const QString &pass, const QString &resource); + void start(const TQString &host, const TQString &user, const TQString &pass, const TQString &resource); void close(bool fast=false); Stream & stream(); const LiveRoster & roster() const; const ResourceList & resourceList() const; - void send(const QDomElement &); - void send(const QString &); + void send(const TQDomElement &); + void send(const TQString &); - QString host() const; - QString user() const; - QString pass() const; - QString resource() const; + TQString host() const; + TQString user() const; + TQString pass() const; + TQString resource() const; Jid jid() const; void rosterRequest(); void sendMessage(const Message &); - void sendSubscription(const Jid &, const QString &); + void sendSubscription(const Jid &, const TQString &); void setPresence(const Status &); - void debug(const QString &); - QString genUniqueId(); + void debug(const TQString &); + TQString genUniqueId(); Task *rootTask(); - QDomDocument *doc() const; + TQDomDocument *doc() const; - QString OSName() const; - QString timeZone() const; + TQString OSName() const; + TQString timeZone() const; int timeZoneOffset() const; - QString clientName() const; - QString clientVersion() const; - QString capsNode() const; - QString capsVersion() const; - QString capsExt() const; - - void setOSName(const QString &); - void setTimeZone(const QString &, int); - void setClientName(const QString &); - void setClientVersion(const QString &); - void setCapsNode(const QString &); - void setCapsVersion(const QString &); + TQString clientName() const; + TQString clientVersion() const; + TQString capsNode() const; + TQString capsVersion() const; + TQString capsExt() const; + + void setOSName(const TQString &); + void setTimeZone(const TQString &, int); + void setClientName(const TQString &); + void setClientVersion(const TQString &); + void setCapsNode(const TQString &); + void setCapsVersion(const TQString &); void setIdentity(DiscoItem::Identity); DiscoItem::Identity identity(); - void addExtension(const QString& ext, const Features& f); - void removeExtension(const QString& ext); - const Features& extension(const QString& ext) const; - QStringList extensions() const; + void addExtension(const TQString& ext, const Features& f); + void removeExtension(const TQString& ext); + const Features& extension(const TQString& ext) const; + TQStringList extensions() const; S5BManager *s5bManager() const; IBBManager *ibbManager() const; @@ -606,32 +606,32 @@ namespace XMPP void setFileTransferEnabled(bool b); FileTransferManager *fileTransferManager() const; - bool groupChatJoin(const QString &host, const QString &room, const QString &nick); - bool groupChatJoin(const QString &host, const QString &room, const QString &nick, const QString &password); - void groupChatSetStatus(const QString &host, const QString &room, const Status &); - void groupChatChangeNick(const QString &host, const QString &room, const QString &nick, const Status &); - void groupChatLeave(const QString &host, const QString &room); + bool groupChatJoin(const TQString &host, const TQString &room, const TQString &nick); + bool groupChatJoin(const TQString &host, const TQString &room, const TQString &nick, const TQString &password); + void groupChatSetStatus(const TQString &host, const TQString &room, const Status &); + void groupChatChangeNick(const TQString &host, const TQString &room, const TQString &nick, const Status &); + void groupChatLeave(const TQString &host, const TQString &room); signals: void activated(); void disconnected(); - //void authFinished(bool, int, const QString &); - void rosterRequestFinished(bool, int, const QString &); + //void authFinished(bool, int, const TQString &); + void rosterRequestFinished(bool, int, const TQString &); void rosterItemAdded(const RosterItem &); void rosterItemUpdated(const RosterItem &); void rosterItemRemoved(const RosterItem &); void resourceAvailable(const Jid &, const Resource &); void resourceUnavailable(const Jid &, const Resource &); - void presenceError(const Jid &, int, const QString &); - void subscription(const Jid &, const QString &); + void presenceError(const Jid &, int, const TQString &); + void subscription(const Jid &, const TQString &); void messageReceived(const Message &); - void debugText(const QString &); - void xmlIncoming(const QString &); - void xmlOutgoing(const QString &); + void debugText(const TQString &); + void xmlIncoming(const TQString &); + void xmlOutgoing(const TQString &); void groupChatJoined(const Jid &); void groupChatLeft(const Jid &); void groupChatPresence(const Jid &, const Status &); - void groupChatError(const Jid &, int, const QString &); + void groupChatError(const Jid &, int, const TQString &); void incomingJidLink(); @@ -643,13 +643,13 @@ namespace XMPP //void streamCloseFinished(); void streamError(int); void streamReadyRead(); - void streamIncomingXml(const QString &); - void streamOutgoingXml(const QString &); + void streamIncomingXml(const TQString &); + void streamOutgoingXml(const TQString &); void slotRosterRequestFinished(); // basic daemons - void ppSubscription(const Jid &, const QString &); + void ppSubscription(const Jid &, const TQString &); void ppPresence(const Jid &, const Status &); void pmMessage(const Message &); void prRoster(const Roster &); @@ -661,7 +661,7 @@ namespace XMPP class GroupChat; private: void cleanup(); - void distribute(const QDomElement &); + void distribute(const TQDomElement &); void importRoster(const Roster &); void importRosterItem(const RosterItem &); void updateSelfPresence(const Jid &, const Status &); @@ -702,7 +702,7 @@ namespace XMPP LiveRosterItemPrivate *d; }; - class LiveRoster : public QValueList<LiveRosterItem> + class LiveRoster : public TQValueList<LiveRosterItem> { public: LiveRoster(); diff --git a/kopete/protocols/jabber/libiris/iris/include/xmpp.h b/kopete/protocols/jabber/libiris/iris/include/xmpp.h index dbb1b2cf..12d87d18 100644 --- a/kopete/protocols/jabber/libiris/iris/include/xmpp.h +++ b/kopete/protocols/jabber/libiris/iris/include/xmpp.h @@ -21,13 +21,13 @@ #ifndef XMPP_H #define XMPP_H -#include<qobject.h> -#include<qstring.h> -#include<qhostaddress.h> -#include<qstring.h> -#include<qcstring.h> -#include<qxml.h> -#include<qdom.h> +#include<tqobject.h> +#include<tqstring.h> +#include<tqhostaddress.h> +#include<tqstring.h> +#include<tqcstring.h> +#include<tqxml.h> +#include<tqdom.h> namespace QCA { @@ -51,11 +51,11 @@ namespace XMPP public: virtual ~Debug(); - virtual void msg(const QString &)=0; - virtual void outgoingTag(const QString &)=0; - virtual void incomingTag(const QString &)=0; - virtual void outgoingXml(const QDomElement &)=0; - virtual void incomingXml(const QDomElement &)=0; + virtual void msg(const TQString &)=0; + virtual void outgoingTag(const TQString &)=0; + virtual void incomingTag(const TQString &)=0; + virtual void outgoingXml(const TQDomElement &)=0; + virtual void incomingXml(const TQDomElement &)=0; }; void setDebug(Debug *); @@ -64,16 +64,16 @@ namespace XMPP { Q_OBJECT public: - Connector(QObject *parent=0); + Connector(TQObject *parent=0); virtual ~Connector(); - virtual void connectToServer(const QString &server)=0; + virtual void connectToServer(const TQString &server)=0; virtual ByteStream *stream() const=0; virtual void done()=0; bool useSSL() const; bool havePeerAddress() const; - QHostAddress peerAddress() const; + TQHostAddress peerAddress() const; Q_UINT16 peerPort() const; signals: @@ -83,12 +83,12 @@ namespace XMPP protected: void setUseSSL(bool b); void setPeerAddressNone(); - void setPeerAddress(const QHostAddress &addr, Q_UINT16 port); + void setPeerAddress(const TQHostAddress &addr, Q_UINT16 port); private: bool ssl; bool haveaddr; - QHostAddress addr; + TQHostAddress addr; Q_UINT16 port; }; @@ -97,7 +97,7 @@ namespace XMPP Q_OBJECT public: enum Error { ErrConnectionRefused, ErrHostNotFound, ErrProxyConnect, ErrProxyNeg, ErrProxyAuth, ErrStream }; - AdvancedConnector(QObject *parent=0); + AdvancedConnector(TQObject *parent=0); virtual ~AdvancedConnector(); class Proxy @@ -108,42 +108,42 @@ namespace XMPP ~Proxy(); int type() const; - QString host() const; + TQString host() const; Q_UINT16 port() const; - QString url() const; - QString user() const; - QString pass() const; + TQString url() const; + TQString user() const; + TQString pass() const; int pollInterval() const; - void setHttpConnect(const QString &host, Q_UINT16 port); - void setHttpPoll(const QString &host, Q_UINT16 port, const QString &url); - void setSocks(const QString &host, Q_UINT16 port); - void setUserPass(const QString &user, const QString &pass); + void setHttpConnect(const TQString &host, Q_UINT16 port); + void setHttpPoll(const TQString &host, Q_UINT16 port, const TQString &url); + void setSocks(const TQString &host, Q_UINT16 port); + void setUserPass(const TQString &user, const TQString &pass); void setPollInterval(int secs); private: int t; - QString v_host, v_url; + TQString v_host, v_url; Q_UINT16 v_port; - QString v_user, v_pass; + TQString v_user, v_pass; int v_poll; }; void setProxy(const Proxy &proxy); - void setOptHostPort(const QString &host, Q_UINT16 port); + void setOptHostPort(const TQString &host, Q_UINT16 port); void setOptProbe(bool); void setOptSSL(bool); void changePollInterval(int secs); - void connectToServer(const QString &server); + void connectToServer(const TQString &server); ByteStream *stream() const; void done(); int errorCode() const; signals: - void srvLookup(const QString &server); + void srvLookup(const TQString &server); void srvResult(bool success); void httpSyncStarted(); void httpSyncFinished(); @@ -170,20 +170,20 @@ namespace XMPP { Q_OBJECT public: - TLSHandler(QObject *parent=0); + TLSHandler(TQObject *parent=0); virtual ~TLSHandler(); virtual void reset()=0; - virtual void startClient(const QString &host)=0; - virtual void write(const QByteArray &a)=0; - virtual void writeIncoming(const QByteArray &a)=0; + virtual void startClient(const TQString &host)=0; + virtual void write(const TQByteArray &a)=0; + virtual void writeIncoming(const TQByteArray &a)=0; signals: void success(); void fail(); void closed(); - void readyRead(const QByteArray &a); - void readyReadOutgoing(const QByteArray &a, int plainBytes); + void readyRead(const TQByteArray &a); + void readyReadOutgoing(const TQByteArray &a, int plainBytes); }; class QCATLSHandler : public TLSHandler @@ -197,9 +197,9 @@ namespace XMPP int tlsError() const; void reset(); - void startClient(const QString &host); - void write(const QByteArray &a); - void writeIncoming(const QByteArray &a); + void startClient(const TQString &host); + void write(const TQByteArray &a); + void writeIncoming(const TQByteArray &a); signals: void tlsHandshaken(); @@ -225,45 +225,45 @@ namespace XMPP Jid(); ~Jid(); - Jid(const QString &s); + Jid(const TQString &s); Jid(const char *s); - Jid & operator=(const QString &s); + Jid & operator=(const TQString &s); Jid & operator=(const char *s); - void set(const QString &s); - void set(const QString &domain, const QString &node, const QString &resource=""); + void set(const TQString &s); + void set(const TQString &domain, const TQString &node, const TQString &resource=""); - void setDomain(const QString &s); - void setNode(const QString &s); - void setResource(const QString &s); + void setDomain(const TQString &s); + void setNode(const TQString &s); + void setResource(const TQString &s); - const QString & domain() const { return d; } - const QString & node() const { return n; } - const QString & resource() const { return r; } - const QString & bare() const { return b; } - const QString & full() const { return f; } + const TQString & domain() const { return d; } + const TQString & node() const { return n; } + const TQString & resource() const { return r; } + const TQString & bare() const { return b; } + const TQString & full() const { return f; } - Jid withNode(const QString &s) const; - Jid withResource(const QString &s) const; + Jid withNode(const TQString &s) const; + Jid withResource(const TQString &s) const; bool isValid() const; bool isEmpty() const; bool compare(const Jid &a, bool compareRes=true) const; - static bool validDomain(const QString &s, QString *norm=0); - static bool validNode(const QString &s, QString *norm=0); - static bool validResource(const QString &s, QString *norm=0); + static bool validDomain(const TQString &s, TQString *norm=0); + static bool validNode(const TQString &s, TQString *norm=0); + static bool validResource(const TQString &s, TQString *norm=0); // TODO: kill these later - const QString & host() const { return d; } - const QString & user() const { return n; } - const QString & userHost() const { return b; } + const TQString & host() const { return d; } + const TQString & user() const { return n; } + const TQString & userHost() const { return b; } private: void reset(); void update(); - QString f, b, d, n, r; + TQString f, b, d, n, r; bool valid; }; @@ -303,42 +303,42 @@ namespace XMPP class Error { public: - Error(int type=Cancel, int condition=UndefinedCondition, const QString &text="", const QDomElement &appSpec=QDomElement()); + Error(int type=Cancel, int condition=UndefinedCondition, const TQString &text="", const TQDomElement &appSpec=TQDomElement()); int type; int condition; - QString text; - QDomElement appSpec; + TQString text; + TQDomElement appSpec; }; bool isNull() const; - QDomElement element() const; - QString toString() const; + TQDomElement element() const; + TQString toString() const; - QDomDocument & doc() const; - QString baseNS() const; - QString xhtmlImNS() const; - QString xhtmlNS() const; - QDomElement createElement(const QString &ns, const QString &tagName); - QDomElement createTextElement(const QString &ns, const QString &tagName, const QString &text); - QDomElement createXHTMLElement(const QString &xHTML); - void appendChild(const QDomElement &e); + TQDomDocument & doc() const; + TQString baseNS() const; + TQString xhtmlImNS() const; + TQString xhtmlNS() const; + TQDomElement createElement(const TQString &ns, const TQString &tagName); + TQDomElement createTextElement(const TQString &ns, const TQString &tagName, const TQString &text); + TQDomElement createXHTMLElement(const TQString &xHTML); + void appendChild(const TQDomElement &e); Kind kind() const; void setKind(Kind k); Jid to() const; Jid from() const; - QString id() const; - QString type() const; - QString lang() const; + TQString id() const; + TQString type() const; + TQString lang() const; void setTo(const Jid &j); void setFrom(const Jid &j); - void setId(const QString &id); - void setType(const QString &type); - void setLang(const QString &lang); + void setId(const TQString &id); + void setType(const TQString &type); + void setLang(const TQString &lang); Error error() const; void setError(const Error &err); @@ -346,8 +346,8 @@ namespace XMPP private: friend class Stream; - Stanza(Stream *s, Kind k, const Jid &to, const QString &type, const QString &id); - Stanza(Stream *s, const QDomElement &e); + Stanza(Stream *s, Kind k, const Jid &to, const TQString &type, const TQString &id); + Stanza(Stream *s, const TQDomElement &e); class Private; Private *d; @@ -370,13 +370,13 @@ namespace XMPP SystemShutdown }; - Stream(QObject *parent=0); + Stream(TQObject *parent=0); virtual ~Stream(); - virtual QDomDocument & doc() const=0; - virtual QString baseNS() const=0; - virtual QString xhtmlImNS() const=0; - virtual QString xhtmlNS() const=0; + virtual TQDomDocument & doc() const=0; + virtual TQString baseNS() const=0; + virtual TQString xhtmlImNS() const=0; + virtual TQString xhtmlNS() const=0; virtual bool old() const=0; virtual void close()=0; @@ -385,13 +385,13 @@ namespace XMPP virtual void write(const Stanza &s)=0; virtual int errorCondition() const=0; - virtual QString errorText() const=0; - virtual QDomElement errorAppSpec() const=0; + virtual TQString errorText() const=0; + virtual TQDomElement errorAppSpec() const=0; - Stanza createStanza(Stanza::Kind k, const Jid &to="", const QString &type="", const QString &id=""); - Stanza createStanza(const QDomElement &e); + Stanza createStanza(Stanza::Kind k, const Jid &to="", const TQString &type="", const TQString &id=""); + Stanza createStanza(const TQDomElement &e); - static QString xmlToString(const QDomElement &e, bool clip=false); + static TQString xmlToString(const TQDomElement &e, bool clip=false); signals: void connectionClosed(); @@ -450,8 +450,8 @@ namespace XMPP BindConflict // resource in-use }; - ClientStream(Connector *conn, TLSHandler *tlsHandler=0, QObject *parent=0); - ClientStream(const QString &host, const QString &defRealm, ByteStream *bs, QCA::TLS *tls=0, QObject *parent=0); // server + ClientStream(Connector *conn, TLSHandler *tlsHandler=0, TQObject *parent=0); + ClientStream(const TQString &host, const TQString &defRealm, ByteStream *bs, QCA::TLS *tls=0, TQObject *parent=0); // server ~ClientStream(); Jid jid() const; @@ -461,13 +461,13 @@ namespace XMPP bool isAuthenticated() const; // login params - void setUsername(const QString &s); - void setPassword(const QString &s); - void setRealm(const QString &s); + void setUsername(const TQString &s); + void setPassword(const TQString &s); + void setRealm(const TQString &s); void continueAfterParams(); // SASL information - QString saslMechanism() const; + TQString saslMechanism() const; int saslSSF() const; // binding @@ -478,14 +478,14 @@ namespace XMPP void setRequireMutualAuth(bool); void setSSFRange(int low, int high); void setOldOnly(bool); - void setSASLMechanism(const QString &s); - void setLocalAddr(const QHostAddress &addr, Q_UINT16 port); + void setSASLMechanism(const TQString &s); + void setLocalAddr(const TQHostAddress &addr, Q_UINT16 port); // reimplemented - QDomDocument & doc() const; - QString baseNS() const; - QString xhtmlImNS() const; - QString xhtmlNS() const; + TQDomDocument & doc() const; + TQString baseNS() const; + TQString xhtmlImNS() const; + TQString xhtmlNS() const; bool old() const; void close(); @@ -494,11 +494,11 @@ namespace XMPP void write(const Stanza &s); int errorCondition() const; - QString errorText() const; - QDomElement errorAppSpec() const; + TQString errorText() const; + TQDomElement errorAppSpec() const; // extra - void writeDirect(const QString &s); + void writeDirect(const TQString &s); void setNoopTime(int mills); signals: @@ -507,8 +507,8 @@ namespace XMPP void needAuthParams(bool user, bool pass, bool realm); void authenticated(); void warning(int); - void incomingXml(const QString &s); - void outgoingXml(const QString &s); + void incomingXml(const TQString &s); + void outgoingXml(const TQString &s); public slots: void continueAfterWarning(); @@ -527,10 +527,10 @@ namespace XMPP void ss_tlsClosed(); void ss_error(int); - void sasl_clientFirstStep(const QString &mech, const QByteArray *clientInit); - void sasl_nextStep(const QByteArray &stepData); + void sasl_clientFirstStep(const TQString &mech, const TQByteArray *clientInit); + void sasl_nextStep(const TQByteArray &stepData); void sasl_needParams(bool user, bool authzid, bool pass, bool realm); - void sasl_authCheck(const QString &user, const QString &authzid); + void sasl_authCheck(const TQString &user, const TQString &authzid); void sasl_authenticated(); void sasl_error(int); |