Malloy
Toggle main menu visibility
Loading...
Searching...
No Matches
lib
malloy
client
http
request_result.hpp
1
#pragma once
2
3
#include "../type_traits.hpp"
4
#include "../../core/error.hpp"
5
#include "../../core/mp.hpp"
6
7
namespace
malloy::client::http
8
{
9
13
// ToDo: Instead of this function, should we return a pair or tuple so we can write: auto [ec, resp] = co_await foo(); ?
14
template
<concepts::response_filter Filter>
15
struct
request_result
16
{
20
malloy::error_code
error_code
;
21
30
malloy::mp::filter_resp_t<Filter>
response
;
31
32
request_result() =
default
;
33
34
explicit
35
request_result(
malloy::error_code
ec) :
36
error_code
{ ec }
37
{
38
}
39
};
40
41
}
malloy::mp::filter_resp_t
unwrap_variant< to_responses< bodies_for_t< Filter > > > filter_resp_t
Resolves to the type that must be taken in callbacks handling responses for Filter.
Definition
mp.hpp:65
malloy::error_code
boost::beast::error_code error_code
Error code used to signify errors without throwing. Truthy means it holds an error.
Definition
error.hpp:9
malloy::client::http::request_result::response
malloy::mp::filter_resp_t< Filter > response
Definition
request_result.hpp:30
malloy::client::http::request_result::error_code
malloy::error_code error_code
Definition
request_result.hpp:20
Generated by
1.18.0