ipfs-chromium
Loading...
Searching...
No Matches
http_api.h
1#ifndef IPFS_CHROMIUM_HTTP_API_H
2#define IPFS_CHROMIUM_HTTP_API_H
3
4#include <ipfs_client/http_request_description.h>
5#include <functional>
6
7namespace ipfs::ctx {
11class HttpApi {
12 public:
16 using Hdrs = std::function<std::string(std::string_view)>;
17 using OnComplete = std::function<void(std::int16_t, std::string_view, Hdrs)>;
18 using Canceller = std::function<void()>;
19 virtual Canceller SendHttpRequest(ReqDesc, OnComplete cb) const = 0;
20
21 virtual ~HttpApi() noexcept {}
22};
23} // namespace ipfs::ctx
24
25#endif // IPFS_CHROMIUM_HTTP_API_H
Definition http_api.h:11
Definition http_request_description.h:12