-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathjsonParser.hpp
More file actions
18 lines (15 loc) · 802 Bytes
/
jsonParser.hpp
File metadata and controls
18 lines (15 loc) · 802 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#include <stdio.h>
#include <regex>
#include <iostream>
using namespace std;
string parseLastMessageId(string jsonResponse);
string parseGuildId(string jsonResponse);
std::map<string,std::vector<string>> parseMessages(string jsonMessages);
std::string parseChannels(string jsonResponse);
std::string executeRegex(std::regex regex, const std::string s);
std::vector<std::string> extractAllRegexPatterns(string s, regex r);
std::map<string,std::vector<string>> constructParsedMsgMap(std::vector<std::string> id,std::vector<std::string> content,std::vector<std::string> userName);
string convertToString(char buf[],int len);
std::vector<string> splitString(string s, string delimiter); // splits string into two with using a delimiter
string extractResponseCode(string s);
bool isBot(string userName);