#include <chatraid.h>
A concrete implemenation of IChatRaid.
◆ CancelCallback
◆ DisposerFunc
◆ JoinCallback
◆ LeaveCallback
◆ StartCallback
◆ State
| Enumerator |
|---|
| Uninitialized | |
| Initialized | |
| ShuttingDown | |
| Inert | The component doesn't require shutting down.
|
◆ ChatRaid()
| ttv::chat::ChatRaid::ChatRaid |
( |
const std::shared_ptr< User > & |
user, |
|
|
ChannelId |
sourceChannelId |
|
) |
| |
◆ AddTopic()
| virtual void ttv::PubSubComponentBase::AddTopic |
( |
const std::string & |
topic | ) |
|
|
protectedvirtualinherited |
◆ Cancel()
As a channel moderator or broadcaster, this cancels a raid. This only works if a raid has been started and is currently underway.
- Parameters
-
| [in] | targetUserId | The id of the user that is being targetted by the raid. |
| [in] | callback | Callback function called after cancelling the raid. Can be null. |
- Returns
- TTV_EC_SUCCESS: The raid was cancelled successfully.
- TTV_EC_SHUT_DOWN: The chat module is not initialized.
- TTV_EC_NEED_TO_LOGIN: User needs to be logged in to leave the raid.
- TTV_EC_AUTHENTICATION: User has an invalid OAuth token.
Implements ttv::chat::IChatRaid.
◆ CheckShutdown()
| virtual bool ttv::PubSubComponentBase::CheckShutdown |
( |
| ) |
|
|
overrideprotectedvirtualinherited |
◆ CompleteShutdown()
| virtual void ttv::chat::ChatRaid::CompleteShutdown |
( |
| ) |
|
|
overrideprivatevirtual |
◆ CompleteTask()
| void ttv::Component::CompleteTask |
( |
Task * |
task | ) |
|
|
protectedinherited |
◆ Dispose()
This should be called when the application is done with the instance.
Implements ttv::chat::IChatRaid.
◆ GetComponentName()
| static std::string ttv::chat::ChatRaid::GetComponentName |
( |
| ) |
|
|
inlinestatic |
◆ GetLoggerName()
| virtual std::string ttv::chat::ChatRaid::GetLoggerName |
( |
| ) |
const |
|
overridevirtual |
◆ GetState()
| virtual State ttv::Component::GetState |
( |
| ) |
const |
|
overridevirtualinherited |
◆ GetTaskRunner()
| std::shared_ptr<TaskRunner> ttv::Component::GetTaskRunner |
( |
| ) |
|
|
inlineinherited |
◆ HandleRaidStatus()
| void ttv::chat::ChatRaid::HandleRaidStatus |
( |
RaidStatus & |
status, |
|
|
bool |
isCancel |
|
) |
| |
|
private |
◆ Initialize()
◆ IsTaskRunning()
| bool ttv::Component::IsTaskRunning |
( |
Task * |
task | ) |
const |
|
protectedinherited |
◆ Join()
As a viewer, joins the raid.
- Parameters
-
| [in] | raidId | The id of the raid that is being joined. |
| [in] | callback | Callback function called after joining the raid. Can be null. |
- Returns
- TTV_EC_SUCCESS: The raid was joined successfully.
- TTV_EC_SHUT_DOWN: The chat module is not initialized.
- TTV_EC_NEED_TO_LOGIN: User needs to be logged in to participate in raid.
- TTV_EC_AUTHENTICATION: User has an invalid OAuth token.
Implements ttv::chat::IChatRaid.
◆ Leave()
As a viewer, leaves the raid. You can only leave a raid if you have previously joined.
- Parameters
-
| [in] | raidId | The id of the raid that is being left. |
| [in] | callback | Callback function called after leaving the raid. Can be null. |
- Returns
- TTV_EC_SUCCESS: The raid was left successfully.
- TTV_EC_SHUT_DOWN: The chat module is not initialized.
- TTV_EC_NEED_TO_LOGIN: User needs to be logged in to participate in raid.
- TTV_EC_AUTHENTICATION: User has an invalid OAuth token.
Implements ttv::chat::IChatRaid.
◆ Log()
| void ttv::UserComponent::Log |
( |
TTV_MessageLevel |
level, |
|
|
const char * |
format, |
|
|
|
... |
|
) |
| |
|
protectedinherited |
◆ OnTopicListenerRemoved()
| virtual void ttv::PubSubComponentBase::OnTopicListenerRemoved |
( |
const std::string & |
topic, |
|
|
TTV_ErrorCode |
ec |
|
) |
| |
|
virtualinherited |
◆ OnTopicMessageReceived()
| void ttv::chat::ChatRaid::OnTopicMessageReceived |
( |
const std::string & |
topic, |
|
|
const json::Value & |
msg |
|
) |
| |
|
overridevirtual |
◆ OnTopicSubscribeStateChanged()
◆ OnUserAuthenticationIssue()
| virtual void ttv::UserComponent::OnUserAuthenticationIssue |
( |
std::shared_ptr< const OAuthToken > |
oauthToken, |
|
|
TTV_ErrorCode |
ec |
|
) |
| |
|
protectedvirtualinherited |
◆ OnUserInfoFetchComplete()
| virtual void ttv::UserComponent::OnUserInfoFetchComplete |
( |
TTV_ErrorCode |
ec | ) |
|
|
protectedvirtualinherited |
◆ OnUserLogInComplete()
| virtual void ttv::UserComponent::OnUserLogInComplete |
( |
TTV_ErrorCode |
ec | ) |
|
|
protectedvirtualinherited |
◆ OnUserLogOutComplete()
| virtual void ttv::UserComponent::OnUserLogOutComplete |
( |
TTV_ErrorCode |
ec | ) |
|
|
protectedvirtualinherited |
◆ SetClientState()
| virtual void ttv::Component::SetClientState |
( |
State |
state | ) |
|
|
protectedvirtualinherited |
◆ SetDisposer()
| void ttv::PubSubComponentBase::SetDisposer |
( |
DisposerFunc && |
func | ) |
|
|
inlineinherited |
◆ SetListener()
◆ SetServerState()
| virtual void ttv::Component::SetServerState |
( |
State |
state | ) |
|
|
protectedvirtualinherited |
◆ SetState()
| virtual void ttv::Component::SetState |
( |
State |
state | ) |
|
|
protectedvirtualinherited |
◆ SetTaskRunner()
| virtual void ttv::Component::SetTaskRunner |
( |
std::shared_ptr< TaskRunner > |
taskRunner | ) |
|
|
virtualinherited |
◆ Shutdown()
◆ Start()
As a channel moderator or broadcaster, this starts a raid on the channel targeting the given user.
- Parameters
-
| [in] | targetUserId | The id of the user that is being targetted by the raid. |
| [in] | callback | Callback function called after starting the raid. Can be null. |
- Returns
- TTV_EC_SUCCESS: The raid was started successfully.
- TTV_EC_SHUT_DOWN: The chat module is not initialized.
- TTV_EC_NEED_TO_LOGIN: User needs to be logged in to start a raid.
- TTV_EC_AUTHENTICATION: User has an invalid OAuth token.
Implements ttv::chat::IChatRaid.
◆ StartTask()
◆ SubscribeTopics()
| virtual TTV_ErrorCode ttv::PubSubComponentBase::SubscribeTopics |
( |
| ) |
|
|
protectedvirtualinherited |
◆ Update()
| virtual void ttv::chat::ChatRaid::Update |
( |
| ) |
|
|
overridevirtual |
◆ mDisposerFunc
◆ mListener
◆ mOAuthIssue
| bool ttv::UserComponent::mOAuthIssue |
|
protectedinherited |
Whether or not the internal updates of the component are on hold because of an issue with the OAuth token.
◆ mPubSub
| std::shared_ptr<PubSubClient> ttv::PubSubComponentBase::mPubSub |
|
protectedinherited |
◆ mPubSubTopic
| std::string ttv::chat::ChatRaid::mPubSubTopic |
|
private |
◆ mPubSubTopicListener
◆ mPubSubTopicListenerHelper
◆ mPubSubTopics
| std::vector<std::string> ttv::PubSubComponentBase::mPubSubTopics |
|
protectedinherited |
◆ mRaids
| std::map<std::string, RaidEntry> ttv::chat::ChatRaid::mRaids |
|
private |
◆ mRunningTasks
| std::vector<std::shared_ptr<Task> > ttv::Component::mRunningTasks |
|
protectedinherited |
◆ mShutdownTimeMilliseconds
| uint64_t ttv::Component::mShutdownTimeMilliseconds |
|
protectedinherited |
◆ mSourceChannelId
| ChannelId ttv::chat::ChatRaid::mSourceChannelId |
|
private |
◆ mState
◆ mTaskMutex
| std::mutex ttv::Component::mTaskMutex |
|
mutableprotectedinherited |
◆ mTaskRunner
| std::shared_ptr<TaskRunner> ttv::Component::mTaskRunner |
|
protectedinherited |
◆ mUser
| std::weak_ptr<User> ttv::UserComponent::mUser |
|
protectedinherited |
The documentation for this class was generated from the following file:
- modules/chat/chat_common/include/twitchsdk/chat/internal/chatraid.h