Chatterino
Public Member Functions | Public Attributes | Protected Member Functions | List of all members
chatterino::TwitchIrcServer Class Referencefinal

#include <TwitchIrcServer.hpp>

Inheritance diagram for chatterino::TwitchIrcServer:
[legend]
Collaboration diagram for chatterino::TwitchIrcServer:
[legend]

Public Member Functions

 TwitchIrcServer ()
 
virtual ~TwitchIrcServer () override=default
 
virtual void initialize (Settings &settings, Paths &paths) override
 
void forEachChannelAndSpecialChannels (std::function< void(ChannelPtr)> func)
 
std::shared_ptr< ChannelgetChannelOrEmptyByID (const QString &channelID)
 
void bulkRefreshLiveStatus ()
 
void reloadBTTVGlobalEmotes ()
 
void reloadAllBTTVChannelEmotes ()
 
void reloadFFZGlobalEmotes ()
 
void reloadAllFFZChannelEmotes ()
 
void reloadSevenTVGlobalEmotes ()
 
void reloadAllSevenTVChannelEmotes ()
 
void forEachSeventvEmoteSet (const QString &emoteSetId, std::function< void(TwitchChannel &)> func)
 
void forEachSeventvUser (const QString &userId, std::function< void(TwitchChannel &)> func)
 
void dropSeventvChannel (const QString &userID, const QString &emoteSetID)
 
const BttvEmotesgetBttvEmotes () const
 
const FfzEmotesgetFfzEmotes () const
 
const SeventvEmotesgetSeventvEmotes () const
 
- Public Member Functions inherited from chatterino::AbstractIrcServer
virtual ~AbstractIrcServer ()=default
 
void initializeIrc ()
 
void connect ()
 
void disconnect ()
 
void sendMessage (const QString &channelName, const QString &message)
 
void sendRawMessage (const QString &rawMessage)
 
ChannelPtr getOrAddChannel (const QString &dirtyChannelName)
 
ChannelPtr getChannelOrEmpty (const QString &dirtyChannelName)
 
std::vector< std::weak_ptr< Channel > > getChannels ()
 
void addFakeMessage (const QString &data)
 
void addGlobalSystemMessage (const QString &messageText)
 
void forEachChannel (std::function< void(ChannelPtr)> func)
 
- Public Member Functions inherited from chatterino::Singleton
virtual ~Singleton ()=default
 
virtual void save ()
 

Public Attributes

Atomic< QString > lastUserThatWhisperedMe
 
const ChannelPtr whispersChannel
 
const ChannelPtr mentionsChannel
 
const ChannelPtr liveChannel
 
IndirectChannel watchingChannel
 
PubSubpubsub
 
std::unique_ptr< SeventvEventAPIseventvEventAPI
 
- Public Attributes inherited from chatterino::AbstractIrcServer
pajlada::Signals::NoArgSignal connected
 
pajlada::Signals::NoArgSignal disconnected
 

Protected Member Functions

virtual void initializeConnection (IrcConnection *connection, ConnectionType type) override
 
virtual std::shared_ptr< ChannelcreateChannel (const QString &channelName) override
 
virtual void privateMessageReceived (Communi::IrcPrivateMessage *message) override
 
virtual void readConnectionMessageReceived (Communi::IrcMessage *message) override
 
virtual void writeConnectionMessageReceived (Communi::IrcMessage *message) override
 
virtual std::shared_ptr< ChannelgetCustomChannel (const QString &channelname) override
 
virtual QString cleanChannelName (const QString &dirtyChannelName) override
 
virtual bool hasSeparateWriteConnection () const override
 
- Protected Member Functions inherited from chatterino::AbstractIrcServer
 AbstractIrcServer ()
 
virtual void initializeConnectionSignals (IrcConnection *connection, ConnectionType type)
 
virtual void onReadConnected (IrcConnection *connection)
 
virtual void onWriteConnected (IrcConnection *connection)
 
virtual void onDisconnected ()
 
void open (ConnectionType type)
 

Additional Inherited Members

- Public Types inherited from chatterino::AbstractIrcServer
enum  ConnectionType { Read = 1, Write = 2, Both = 3 }
 
- Protected Attributes inherited from chatterino::AbstractIrcServer
QMap< QString, std::weak_ptr< Channel > > channels
 
std::mutex channelMutex
 

Constructor & Destructor Documentation

◆ TwitchIrcServer()

chatterino::TwitchIrcServer::TwitchIrcServer ( )
Here is the call graph for this function:

◆ ~TwitchIrcServer()

virtual chatterino::TwitchIrcServer::~TwitchIrcServer ( )
overridevirtualdefault

Member Function Documentation

◆ bulkRefreshLiveStatus()

void chatterino::TwitchIrcServer::bulkRefreshLiveStatus ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ cleanChannelName()

QString chatterino::TwitchIrcServer::cleanChannelName ( const QString &  dirtyChannelName)
overrideprotectedvirtual

Reimplemented from chatterino::AbstractIrcServer.

◆ createChannel()

std::shared_ptr< Channel > chatterino::TwitchIrcServer::createChannel ( const QString &  channelName)
overrideprotectedvirtual

◆ dropSeventvChannel()

void chatterino::TwitchIrcServer::dropSeventvChannel ( const QString &  userID,
const QString &  emoteSetID 
)

Checks if any channel still needs this userID or emoteSetID. If not, it unsubscribes from the respective messages.

It's currently not possible to share emote sets among users, but it's a commonly requested feature.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ forEachChannelAndSpecialChannels()

void chatterino::TwitchIrcServer::forEachChannelAndSpecialChannels ( std::function< void(ChannelPtr)>  func)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ forEachSeventvEmoteSet()

void chatterino::TwitchIrcServer::forEachSeventvEmoteSet ( const QString &  emoteSetId,
std::function< void(TwitchChannel &)>  func 
)

Calls func with all twitch channels that have emoteSetId added.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ forEachSeventvUser()

void chatterino::TwitchIrcServer::forEachSeventvUser ( const QString &  userId,
std::function< void(TwitchChannel &)>  func 
)

Calls func with all twitch channels where the seventv-user-id is userId.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getBttvEmotes()

const BttvEmotes & chatterino::TwitchIrcServer::getBttvEmotes ( ) const

◆ getChannelOrEmptyByID()

std::shared_ptr< Channel > chatterino::TwitchIrcServer::getChannelOrEmptyByID ( const QString &  channelID)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getCustomChannel()

std::shared_ptr< Channel > chatterino::TwitchIrcServer::getCustomChannel ( const QString &  channelname)
overrideprotectedvirtual

Reimplemented from chatterino::AbstractIrcServer.

Here is the call graph for this function:

◆ getFfzEmotes()

const FfzEmotes & chatterino::TwitchIrcServer::getFfzEmotes ( ) const
Here is the caller graph for this function:

◆ getSeventvEmotes()

const SeventvEmotes & chatterino::TwitchIrcServer::getSeventvEmotes ( ) const
Here is the caller graph for this function:

◆ hasSeparateWriteConnection()

bool chatterino::TwitchIrcServer::hasSeparateWriteConnection ( ) const
overrideprotectedvirtual

Implements chatterino::AbstractIrcServer.

Here is the call graph for this function:

◆ initialize()

void chatterino::TwitchIrcServer::initialize ( Settings settings,
Paths paths 
)
overridevirtual

Reimplemented from chatterino::Singleton.

Here is the call graph for this function:

◆ initializeConnection()

void chatterino::TwitchIrcServer::initializeConnection ( IrcConnection connection,
ConnectionType  type 
)
overrideprotectedvirtual

Implements chatterino::AbstractIrcServer.

Here is the call graph for this function:

◆ privateMessageReceived()

void chatterino::TwitchIrcServer::privateMessageReceived ( Communi::IrcPrivateMessage *  message)
overrideprotectedvirtual

Reimplemented from chatterino::AbstractIrcServer.

Here is the call graph for this function:

◆ readConnectionMessageReceived()

void chatterino::TwitchIrcServer::readConnectionMessageReceived ( Communi::IrcMessage *  message)
overrideprotectedvirtual

Reimplemented from chatterino::AbstractIrcServer.

Here is the call graph for this function:

◆ reloadAllBTTVChannelEmotes()

void chatterino::TwitchIrcServer::reloadAllBTTVChannelEmotes ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ reloadAllFFZChannelEmotes()

void chatterino::TwitchIrcServer::reloadAllFFZChannelEmotes ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ reloadAllSevenTVChannelEmotes()

void chatterino::TwitchIrcServer::reloadAllSevenTVChannelEmotes ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ reloadBTTVGlobalEmotes()

void chatterino::TwitchIrcServer::reloadBTTVGlobalEmotes ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ reloadFFZGlobalEmotes()

void chatterino::TwitchIrcServer::reloadFFZGlobalEmotes ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ reloadSevenTVGlobalEmotes()

void chatterino::TwitchIrcServer::reloadSevenTVGlobalEmotes ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ writeConnectionMessageReceived()

void chatterino::TwitchIrcServer::writeConnectionMessageReceived ( Communi::IrcMessage *  message)
overrideprotectedvirtual

Reimplemented from chatterino::AbstractIrcServer.

Here is the call graph for this function:

Member Data Documentation

◆ lastUserThatWhisperedMe

Atomic<QString> chatterino::TwitchIrcServer::lastUserThatWhisperedMe

◆ liveChannel

const ChannelPtr chatterino::TwitchIrcServer::liveChannel

◆ mentionsChannel

const ChannelPtr chatterino::TwitchIrcServer::mentionsChannel

◆ pubsub

PubSub* chatterino::TwitchIrcServer::pubsub

◆ seventvEventAPI

std::unique_ptr<SeventvEventAPI> chatterino::TwitchIrcServer::seventvEventAPI

◆ watchingChannel

IndirectChannel chatterino::TwitchIrcServer::watchingChannel

◆ whispersChannel

const ChannelPtr chatterino::TwitchIrcServer::whispersChannel

The documentation for this class was generated from the following files: