blob: cce8ae717dc9aba7d6c36d38e967963d102a23ad (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
#pragma once
#include <nlohmann/json.hpp>
#include <string>
#include <vector>
#include "emotespp/emotes.hpp"
#include "ixwebsocket/IXWebSocket.h"
namespace emotespp {
class SevenTVWebsocketClient : public RetrieveEmoteWebsocket<Emote> {
public:
SevenTVWebsocketClient();
void subscribe_emote_set(const std::string &emote_set_id);
void unsubscribe_emote_set(const std::string &emote_set_id);
void start();
private:
Emote create_emote(const nlohmann::json &data);
std::vector<std::string> ids;
ix::WebSocket websocket;
bool is_connected = false;
};
}
|