1 #ifndef _KVI_IRCCONNECTION_H_
2 #define _KVI_IRCCONNECTION_H_
40 #include <QStringList>
47 class KviIrcNetworkData;
287 return m_pAntiCtcpFloodData;
302 return m_pNetsplitDetectorData;
317 return m_pAsyncWhoisData;
341 return m_pNotifyListManager;
371 const QString & currentNetworkName();
377 const QString & currentNickName();
383 const QString & currentUserName();
389 const QString & currentServerName();
422 int getCommonChannels(
const QString & szNick, QString & szChansBuffer,
bool bAddEscapeSequences =
true);
460 void keepChannelsOpenAfterDisconnect();
466 void closeAllChannels();
472 void closeAllQueries();
514 CreateQueryVisibilityFollowSettings
526 KviQueryWindow * createQuery(
const QString & szNick, CreateQueryVisibilityMode eVisibilityMode = CreateQueryVisibilityFollowSettings);
550 void keepQueriesOpenAfterDisconnect();
559 void resurrectDeadQueries();
566 void restartLagMeter();
595 bool sendData(
const char * pcBuffer,
int iBuflen = -1);
622 bool sendFmtData(
const char * pcFmt, ...);
629 void clearOutputQueue(
bool bPrivateMessagesOnly);
635 unsigned int outputQueueSize();
646 void incomingMessage(
const char * pcMessage);
656 void incomingMessageNoFilter(
const char * pcMessage);
669 inline QTextCodec *
textCodec() {
return m_pTextCodec; };
692 void setEncoding(
const QString & szEncoding);
702 QString decodeText(
const char * szText);
712 QByteArray encodeText(
const QString & szText);
726 void delayedStartNotifyList();
736 void resolveLocalHost();
738 #ifdef COMPILE_SSL_SUPPORT
739 void handleFailedInitialStartTls();
740 bool trySTARTTLS(
bool bAppendPing);
741 void enableStartTlsSupport(
bool bEnable);
760 void useRealName(
const QString & szRealName);
766 void loginToIrcServer();
773 void joinChannels(
const QList<QPair<QString, QString>> & lChannelsAndPasses);
778 void gatherChannelAndPasswordPairs(QList<QPair<QString, QString>> & lChannelsAndPasses);
783 void gatherQueryNames(QStringList & lQueryNames);
795 QString pickNextLoginNickName(
bool bForceDefaultIfPrimaryNicknamesEmpty,
const QString & szBaseNickForRandomChoices, QString & szChoiceDescriptionBuffer);
805 void endOfMotdReceived();
814 void serverInfoReceived(
const QString & szServerName,
const QString & szUserModes,
const QString & szChanModes);
820 void handleAuthenticate(
KviCString & szResponse);
826 void handleInitialCapLs();
832 void handleFailedInitialCapLs();
838 void handleInitialCapAck();
844 void handleInitialCapNak();
850 void endInitialCapNegotiation();
857 void changeAwayState(
bool bAway);
868 void userInfoReceived(
const QString & szUserName,
const QString & szHostName);
875 void nickChange(
const QString & szNewNick);
883 bool changeUserMode(
char cMode,
bool bSet);
890 void loginComplete(
const QString & szNickName);
927 void linkAttemptFailed(
int iError);
933 void linkEstablished();
939 void linkTerminated();
946 void setupTextCodec();
952 void setupSrvCodec();
958 void unhighlightAllChannels();
964 void unhighlightAllQueries();
970 void restartNotifyList();
982 void awayStateChanged();
988 void userModeChanged();
994 void nickNameChanged();
1014 void chanListChanged();
1019 #endif //_KVI_IRCCONNECTION_H_
QTextCodec * serverCodec()
Returns a pointer to the current global codec for inbound data.
Definition: KviIrcConnection.h:678
KviIrcUserDataBase * userDataBase()
Returns a pointer to the big connection user database.
Definition: KviIrcConnection.h:232
Definition: KviIrcConnection.h:510
KviIrcConnectionServerInfo * serverInfo()
Returns a pointer to the KviIrcConnectionServerInfo object.
Definition: KviIrcConnection.h:259
Definition: KviCString.h:105
KviIrcUserDataBase * m_pUserDataBase
Definition: KviIrcConnection.h:166
Class to enqueue commands to IRC server.
Definition: KviIrcConnectionRequestQueue.h:47
KviIrcConnectionStatistics * m_pStatistics
Definition: KviIrcConnection.h:177
Definition: KviMainWindow.h:60
Definition: KviConsoleWindow.h:75
The class which manages the irc servers.
Definition: KviIrcServer.h:51
Definition: KviIrcConnectionAsyncWhoisData.h:63
#define KVIRC_API
Definition: kvi_settings.h:128
char s char s char s s s s s char char c s *s c s s s d c s *s d c d d d d c
Definition: KviIrcNumericCodes.h:391
KviDnsResolver * m_pLocalhostDns
Definition: KviIrcConnection.h:179
KviConsoleWindow * console()
Returns a pointer to the owning console.
Definition: KviIrcConnection.h:191
An abstraction of a connection to an IRC server.
Definition: KviIrcConnection.h:95
KviPointerList< KviChannelWindow > * channelList()
Returns the list of the channels bound to the current connection.
Definition: KviIrcConnection.h:365
KviPointerList< KviChannelWindow > * m_pChannelList
Definition: KviIrcConnection.h:163
KviIrcContext * context()
Returns a pointer to the owning KviIrcContext.
Definition: KviIrcConnection.h:199
Definition: KviIrcConnection.h:137
KviConsoleWindow * m_pConsole
Definition: KviIrcConnection.h:142
State
The possible "high level" states of this connection.
Definition: KviIrcConnection.h:134
KviUserIdentity * m_pUserIdentity
Definition: KviIrcConnection.h:154
Definition: KviNotifyList.h:41
Definition: KviDataBuffer.h:30
Definition: KviProxy.h:37
KviIrcConnectionServerInfo * m_pServerInfo
Definition: KviIrcConnection.h:159
QTimer * m_pNotifyListTimer
Definition: KviIrcConnection.h:169
#define kvi_time_t
Definition: KviTimeUtils.h:43
State state()
Returns the current state of the connection.
Definition: KviIrcConnection.h:223
KviIrcConnectionUserInfo * userInfo()
Returns a pointer to the KviIrcConnectionUserInfo object.
Definition: KviIrcConnection.h:245
The class which manages a query.
Definition: KviQueryWindow.h:49
#define q
Definition: detector.cpp:81
KviIrcConnectionAntiCtcpFloodData * antiCtcpFloodData()
Returns a pointer to the KviIrcConnectionAntiCtcpFloodData object.
Definition: KviIrcConnection.h:285
KviIrcConnectionStateData * stateData()
Returns a pointer to the KviIrcConnectionStateData object.
Definition: KviIrcConnection.h:273
bool m_bIdentdAttached
Definition: KviIrcConnection.h:146
Definition: KviIrcConnection.h:506
Definition: KviIrcConnectionStatistics.h:31
Definition: KviIrcConnectionUserInfo.h:31
KviIrcConnectionRequestQueue * requestQueue()
Returns a pointer to the current KviIrcConnectionRequestQueue.
Definition: KviIrcConnection.h:357
KviPointerList< KviQueryWindow > * queryList()
Returns the list of the currently open queries.
Definition: KviIrcConnection.h:496
User identity handling class.
Definition: KviUserIdentity.h:42
KviLagMeter * m_pLagMeter
Definition: KviIrcConnection.h:171
KviLagMeter * lagMeter()
Returns a pointer to the current KviLagMeter.
Definition: KviIrcConnection.h:351
Definition: KviIrcConnectionServerInfo.h:296
KviNotifyListManager * m_pNotifyListManager
Definition: KviIrcConnection.h:168
The KviDnsResolver class.
Definition: KviDnsResolver.h:93
QTextCodec * m_pSrvCodec
Definition: KviIrcConnection.h:181
KviIrcConnectionTarget * target()
Returns the target of this connection.
Definition: KviIrcConnection.h:209
Middle stack class for IRC connection.
Definition: KviIrcLink.h:55
KviPointerList< KviQueryWindow > * m_pQueryList
Definition: KviIrcConnection.h:164
C++ Template based double linked pointer list class.
KviIrcConnectionStateData * m_pStateData
Definition: KviIrcConnection.h:161
Class which manages the list of identity profiles.
Definition: KviIdentityProfileSet.h:44
QTextCodec * textCodec()
Returns a pointer to the current global codec for outbound text.
Definition: KviIrcConnection.h:669
QTextCodec * m_pTextCodec
Definition: KviIrcConnection.h:182
Definition: KviIrcConnectionStateData.h:40
Definition: KviIrcConnection.h:136
KviIrcLink * link()
Returns the underlying KviIrcLink object.
Definition: KviIrcConnection.h:217
KviIrcConnectionNetsplitDetectorData * m_pNetsplitDetectorData
Definition: KviIrcConnection.h:174
The class which manages the user database.
Definition: KviIrcUserDataBase.h:45
KviIrcConnectionAsyncWhoisData * asyncWhoisData()
Returns a pointer to the KviIrcConnectionAsyncWhoisData object.
Definition: KviIrcConnection.h:315
CreateQueryVisibilityMode
Definition: KviIrcConnection.h:501
Definition: KviIrcServerParser.h:115
Definition: KviLagMeter.h:45
KviIrcConnectionTarget * m_pTarget
Definition: KviIrcConnection.h:148
KviIrcContext * m_pContext
Definition: KviIrcConnection.h:143
State m_eState
Definition: KviIrcConnection.h:145
KviIrcConnectionUserInfo * m_pUserInfo
Definition: KviIrcConnection.h:157
KviIrcConnectionRequestQueue * m_pRequestQueue
Definition: KviIrcConnection.h:183
This file contains compile time settings.
KviIrcConnectionStatistics * statistics()
Returns a pointer to the KviIrcConnectionStatistics object.
Definition: KviIrcConnection.h:330
KviIrcConnectionAsyncWhoisData * m_pAsyncWhoisData
Definition: KviIrcConnection.h:175
KviNotifyListManager * notifyListManager()
Returns a pointer to the current KviNotifyListManager.
Definition: KviIrcConnection.h:339
Definition: KviIrcConnectionTarget.h:35
Definition: KviIrcContext.h:58
This class is the lowest level of the KVIrc networking stack.
Definition: KviIrcSocket.h:71
Definition: KviIrcConnectionAntiCtcpFloodData.h:30
Helper functions for the QString class.
KviIrcConnectionAntiCtcpFloodData * m_pAntiCtcpFloodData
Definition: KviIrcConnection.h:173
Definition: KviIrcConnectionNetsplitDetectorData.h:31
KviIrcConnectionNetsplitDetectorData * netsplitDetectorData()
Returns a pointer to the KviIrcConnectionNetsplitDetectorData object.
Definition: KviIrcConnection.h:300
KviIrcLink * m_pLink
Definition: KviIrcConnection.h:150
The class which manages a channel.
Definition: KviChannelWindow.h:113