ipfs-chromium
block_request_splitter.h
1 #ifndef IPFS_BLOCK_REQUEST_SPLITTER_H_
2 #define IPFS_BLOCK_REQUEST_SPLITTER_H_
3 
4 #include "requestor.h"
5 
6 #include <array>
7 #include <string>
8 
9 namespace ipfs {
10 class Client;
11 }
12 
13 namespace ipfs::gw {
17 class BlockRequestSplitter final : public Requestor {
18  using RequestQ = std::array<std::string, 32>;
19  RequestQ recent_provider_requests;
20  std::size_t old_provider_request = 0UL;
21  HandleOutcome handle(RequestPtr) override;
22  std::string_view name() const override;
23 };
24 } // namespace ipfs::gw
25 
26 #endif // IPFS_BLOCK_REQUEST_SPLITTER_H_
Definition: block_request_splitter.h:17
Definition: requestor.h:22