Twitch SDK (Internal)
chatuserbadges.h
Go to the documentation of this file.
1 /********************************************************************************************
2  * Twitch Broadcasting SDK
3  *
4  * This software is supplied under the terms of a license agreement with Twitch Interactive, Inc. and
5  * may not be copied or used except in accordance with the terms of that agreement
6  * Copyright (c) 2012-2016 Twitch Interactive, Inc.
7  *********************************************************************************************/
8 
9 #pragma once
10 
14 
15 namespace ttv
16 {
17  class User;
18 
19  namespace chat
20  {
21  class ChatUserBadges;
22  }
23 }
24 
29 {
30 public:
31  ChatUserBadges(const std::shared_ptr<User>& user);
32  virtual ~ChatUserBadges();
33 
34  virtual std::string GetLoggerName() const override;
35  static std::string GetComponentName() { return "ttv::chat::ChatUserBadges"; }
36 
37  std::string GetBadgesMessageTag(ChannelId channelId);
38  void SetBadgesMessageTag(ChannelId channelId, const std::string& badgesMessageTag);
39 
40 private:
41  std::unordered_map<ChannelId, std::string> mBadges;
42 };
std::string GetBadgesMessageTag(ChannelId channelId)
Definition: chatuserbadges.h:28
void SetBadgesMessageTag(ChannelId channelId, const std::string &badgesMessageTag)
ChatUserBadges(const std::shared_ptr< User > &user)
JSON (JavaScript Object Notation).
Definition: adsapi.h:16
Definition: component.h:87
static std::string GetComponentName()
Definition: chatuserbadges.h:35
virtual std::string GetLoggerName() const override
uint32_t ChannelId
Definition: coretypes.h:23
std::unordered_map< ChannelId, std::string > mBadges
The mapping of channel ID to the badges message tag.
Definition: chatuserbadges.h:41