tgbot-cpp
Loading...
Searching...
No Matches
Url.h
Go to the documentation of this file.
1#ifndef TGBOT_CPP_URL_H
2#define TGBOT_CPP_URL_H
3
4#include "tgbot/export.h"
5
6#include <string>
7
8namespace TgBot {
9
15class TGBOT_API Url {
16
17public:
18 Url(const std::string& url);
19
23 std::string protocol;
24
28 std::string host;
29
33 std::string path;
34
38 std::string query;
39
43 std::string fragment;
44};
45
46}
47
48#endif //TGBOT_CPP_URL_H
This class parses a string with the url.
Definition Url.h:15
std::string path
Path part of an url including preceding '/' char. Example: /index.html.
Definition Url.h:33
std::string protocol
Protocol part of an url. Example: https://.
Definition Url.h:23
std::string query
Query part of an url without '?' char. Example: a=1&b=2&c=3.
Definition Url.h:38
Url(const std::string &url)
std::string host
Host part of an url. Example: www.example.com.
Definition Url.h:28
std::string fragment
Fragment part of an url without '#' char. Example: section1.
Definition Url.h:43
Definition Api.h:39