Twitch SDK (Internal)
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
ttv::chat::ChatNetworkEvent Class Reference

#include <chatnetworkevent.h>

Public Member Functions

 ChatNetworkEvent ()
 
 ChatNetworkEvent (int idEvent, int nParams,...)
 
 ~ChatNetworkEvent ()
 
void SetEvent (const std::string &evt)
 
const std::string & GetEvent () const
 
void SetEventID (int idEvent)
 
int GetEventID () const
 
void AddParam (const std::string &sParam)
 
const std::string & GetParam (unsigned int iParam) const
 
size_t GetParamCount () const
 
void SetPrefix (const std::string &prefix)
 
const std::string & GetPrefix () const
 
void SetMessageTags (const std::string &raw)
 
const std::map< std::string, std::string > & GetMessageTags () const
 
bool IsIncoming () const
 
void SetIncoming (bool bIncoming)
 
void SetAutoPrefix (bool bAutoPrefix)
 
bool GetAutoPrefix () const
 

Static Public Member Functions

static std::string EventIDToString (int idEvent)
 
static int EventStringToID (const std::string &evt)
 
static int CTCPEventStringToID (const std::string &evt, bool bReply=false)
 
static bool IsReplyEvent (int idEvent)
 
static bool IsCommandEvent (int idEvent)
 
static bool IsCTCPEvent (int idEvent)
 
static bool IsCTCPReplyEvent (int idEvent)
 
static bool IsSystemEvent (int idEvent)
 

Protected Member Functions

void Clear ()
 

Protected Attributes

uint32_t mEventId
 
std::string mEventName
 
std::string mPrefix
 
std::map< std::string, std::string > mMessageTags
 
std::vector< std::string > mParams
 
bool mIncoming
 
bool mAutoPrefix
 

Detailed Description

Wraps an event in the chat system. Events include sending/receiving messages, pings, etc.

Constructor & Destructor Documentation

◆ ChatNetworkEvent() [1/2]

ttv::chat::ChatNetworkEvent::ChatNetworkEvent ( )

◆ ChatNetworkEvent() [2/2]

ttv::chat::ChatNetworkEvent::ChatNetworkEvent ( int  idEvent,
int  nParams,
  ... 
)

◆ ~ChatNetworkEvent()

ttv::chat::ChatNetworkEvent::~ChatNetworkEvent ( )

Member Function Documentation

◆ AddParam()

void ttv::chat::ChatNetworkEvent::AddParam ( const std::string &  sParam)

◆ Clear()

void ttv::chat::ChatNetworkEvent::Clear ( )
protected

◆ CTCPEventStringToID()

static int ttv::chat::ChatNetworkEvent::CTCPEventStringToID ( const std::string &  evt,
bool  bReply = false 
)
static

◆ EventIDToString()

static std::string ttv::chat::ChatNetworkEvent::EventIDToString ( int  idEvent)
static

◆ EventStringToID()

static int ttv::chat::ChatNetworkEvent::EventStringToID ( const std::string &  evt)
static

◆ GetAutoPrefix()

bool ttv::chat::ChatNetworkEvent::GetAutoPrefix ( ) const

◆ GetEvent()

const std::string& ttv::chat::ChatNetworkEvent::GetEvent ( ) const

◆ GetEventID()

int ttv::chat::ChatNetworkEvent::GetEventID ( ) const

◆ GetMessageTags()

const std::map<std::string, std::string>& ttv::chat::ChatNetworkEvent::GetMessageTags ( ) const

◆ GetParam()

const std::string& ttv::chat::ChatNetworkEvent::GetParam ( unsigned int  iParam) const

◆ GetParamCount()

size_t ttv::chat::ChatNetworkEvent::GetParamCount ( ) const

◆ GetPrefix()

const std::string& ttv::chat::ChatNetworkEvent::GetPrefix ( ) const

◆ IsCommandEvent()

static bool ttv::chat::ChatNetworkEvent::IsCommandEvent ( int  idEvent)
static

◆ IsCTCPEvent()

static bool ttv::chat::ChatNetworkEvent::IsCTCPEvent ( int  idEvent)
static

◆ IsCTCPReplyEvent()

static bool ttv::chat::ChatNetworkEvent::IsCTCPReplyEvent ( int  idEvent)
static

◆ IsIncoming()

bool ttv::chat::ChatNetworkEvent::IsIncoming ( ) const

◆ IsReplyEvent()

static bool ttv::chat::ChatNetworkEvent::IsReplyEvent ( int  idEvent)
static

◆ IsSystemEvent()

static bool ttv::chat::ChatNetworkEvent::IsSystemEvent ( int  idEvent)
static

◆ SetAutoPrefix()

void ttv::chat::ChatNetworkEvent::SetAutoPrefix ( bool  bAutoPrefix)

◆ SetEvent()

void ttv::chat::ChatNetworkEvent::SetEvent ( const std::string &  evt)

◆ SetEventID()

void ttv::chat::ChatNetworkEvent::SetEventID ( int  idEvent)

◆ SetIncoming()

void ttv::chat::ChatNetworkEvent::SetIncoming ( bool  bIncoming)

◆ SetMessageTags()

void ttv::chat::ChatNetworkEvent::SetMessageTags ( const std::string &  raw)

◆ SetPrefix()

void ttv::chat::ChatNetworkEvent::SetPrefix ( const std::string &  prefix)

Member Data Documentation

◆ mAutoPrefix

bool ttv::chat::ChatNetworkEvent::mAutoPrefix
protected

◆ mEventId

uint32_t ttv::chat::ChatNetworkEvent::mEventId
protected

◆ mEventName

std::string ttv::chat::ChatNetworkEvent::mEventName
protected

◆ mIncoming

bool ttv::chat::ChatNetworkEvent::mIncoming
protected

◆ mMessageTags

std::map<std::string, std::string> ttv::chat::ChatNetworkEvent::mMessageTags
protected

◆ mParams

std::vector<std::string> ttv::chat::ChatNetworkEvent::mParams
protected

◆ mPrefix

std::string ttv::chat::ChatNetworkEvent::mPrefix
protected

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