25 #include <olp/core/CoreApi.h>
26 #include <olp/core/http/Network.h>
81 class HarCaptureAdapterImpl;
82 std::shared_ptr<HarCaptureAdapterImpl> impl_;
A network adapter that captures HTTP requests and responses, generating a HAR (HTTP Archive) file.
Definition: HarCaptureAdapter.h:54
void Cancel(RequestId id) override
Cancels the request associated with the given RequestId.
HarCaptureAdapter(std::shared_ptr< Network > network, std::string har_out_path)
Constructs a HarCaptureAdapter instance.
SendOutcome Send(NetworkRequest request, Payload payload, Callback callback, HeaderCallback header_callback, DataCallback data_callback) override
Sends the network request.
A network request abstraction for an HTTP request.
Definition: NetworkRequest.h:34
An HTTP client abstraction.
Definition: Network.h:38
std::function< void(const std::uint8_t *data, std::uint64_t offset, std::size_t length)> DataCallback
The callback that is called when a chunk of data is received.
Definition: Network.h:49
std::shared_ptr< std::ostream > Payload
The request and response payload type.
Definition: Network.h:52
std::function< void(std::string key, std::string value)> HeaderCallback
The callback that is called when a header is received.
Definition: Network.h:45
std::function< void(NetworkResponse response)> Callback
The callback that is called when the request is processed or canceled.
Definition: Network.h:41
Rrepresents the outcome of a network request.
Definition: NetworkTypes.h:76
std::uint64_t RequestId
A unique request ID.
Definition: NetworkTypes.h:41
Rules all the other namespaces.
Definition: AppleSignInProperties.h:24