Skip to content

Receiver1/http_url_handler

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

http_url_handler

It is a parser and link builder. This project uses https://github.com/nodejs/http-parser for link parsing. I use vcpkg to connect it.

Parsing URL:

net::http::url url{"https://user@host:8080/path?query=value#fragment"};
std::cout << url.str() << std::endl;

Building URL from scratch:

net::http::url url{};
url.schema("https");
url.user_info("user");
url.host("host");
url.port(8080);
url.path("/path");
url.query("query=value");
url.fragment("fragment");
std::cout << url.str() << std::endl;

Parsing URL query:

auto query = net::http::parse_query(url.query());
for (auto& [key, value] : query) {
  // ...
}

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published