1 #ifndef IPFS_CHROMIUM_BLOCK_SOURCE_H
2 #define IPFS_CHROMIUM_BLOCK_SOURCE_H
4 #include <ipfs_client/gw/gateway_request_type.h>
15 using Clock = std::chrono::system_clock;
20 std::string gateway_url;
21 gw::GatewayRequestType request_type = gw::GatewayRequestType::Zombie;
25 bool operator<(
Category const& r)
const {
26 if (cached != r.cached) {
29 if (request_type != r.request_type) {
30 return request_type < r.request_type;
32 return gateway_url < r.gateway_url;
36 Clock::time_point fetched_at = Clock::now();
37 Clock::duration load_duration = std::chrono::seconds(0);
41 void Deserialize(std::string_view);
42 std::string Serialize()
const;
Definition: block_source.h:19
Definition: block_source.h:12
std::chrono::system_clock Clock
Definition: block_source.h:15