3 #ifndef IPC_CAPNP_INIT_CAPNP_PROXY_H 4 #define IPC_CAPNP_INIT_CAPNP_PROXY_H 12 #pragma GCC diagnostic push 13 #if !defined(__has_warning) 14 #pragma GCC diagnostic ignored "-Wsuggest-override" 15 #elif __has_warning("-Wsuggest-override") 16 #pragma GCC diagnostic ignored "-Wsuggest-override" 21 struct ProxyMethod<
ipc::capnp::messages::Init::MakeEchoParams>
26 namespace init_fields {
29 template<
typename S>
static auto get(
S&& s) -> decltype(s.getThreadMap()) {
return s.getThreadMap(); }
30 template<
typename S>
static bool has(
S&& s) {
return s.hasThreadMap(); }
31 template<
typename S,
typename A>
static void set(
S&& s, A&& a) { s.setThreadMap(std::forward<A>(a)); }
32 template<
typename S,
typename... A>
static decltype(
auto)
init(
S&& s, A&&... a) {
return s.initThreadMap(std::forward<A>(a)...); }
33 template<
typename S>
static bool getWant(
S&& s) {
return s.getWantThreadMap(); }
34 template<
typename S>
static void setWant(
S&& s) { s.setWantThreadMap(
true); }
35 template<
typename S>
static bool getHas(
S&& s) {
return s.getHasThreadMap(); }
36 template<
typename S>
static void setHas(
S&& s) { s.setHasThreadMap(
true); }
40 template<
typename S>
static auto get(
S&& s) -> decltype(s.getContext()) {
return s.getContext(); }
41 template<
typename S>
static bool has(
S&& s) {
return s.hasContext(); }
42 template<
typename S,
typename A>
static void set(
S&& s, A&& a) { s.setContext(std::forward<A>(a)); }
43 template<
typename S,
typename... A>
static decltype(
auto)
init(
S&& s, A&&... a) {
return s.initContext(std::forward<A>(a)...); }
44 template<
typename S>
static bool getWant(
S&& s) {
return s.getWantContext(); }
45 template<
typename S>
static void setWant(
S&& s) { s.setWantContext(
true); }
46 template<
typename S>
static bool getHas(
S&& s) {
return s.getHasContext(); }
47 template<
typename S>
static void setHas(
S&& s) { s.setHasContext(
true); }
51 template<
typename S>
static auto get(
S&& s) -> decltype(s.getResult()) {
return s.getResult(); }
52 template<
typename S>
static bool has(
S&& s) {
return s.hasResult(); }
53 template<
typename S,
typename A>
static void set(
S&& s, A&& a) { s.setResult(std::forward<A>(a)); }
54 template<
typename S,
typename... A>
static decltype(
auto)
init(
S&& s, A&&... a) {
return s.initResult(std::forward<A>(a)...); }
55 template<
typename S>
static bool getWant(
S&& s) {
return s.getWantResult(); }
56 template<
typename S>
static void setWant(
S&& s) { s.setWantResult(
true); }
57 template<
typename S>
static bool getHas(
S&& s) {
return s.getHasResult(); }
58 template<
typename S>
static void setHas(
S&& s) { s.setHasResult(
true); }
63 struct ProxyClient<
ipc::capnp::messages::Init> final :
public ProxyClientCustom<ipc::capnp::messages::Init, interfaces::Init>
66 using ProxyClientCustom::ProxyClientCustom;
68 using M0 = ProxyClientMethodTraits<ipc::capnp::messages::Init::ConstructParams>;
70 using M1 = ProxyClientMethodTraits<ipc::capnp::messages::Init::MakeEchoParams>;
75 struct ProxyServer<
ipc::capnp::messages::Init> :
public ProxyServerCustom<ipc::capnp::messages::Init, interfaces::Init>
78 using ProxyServerCustom::ProxyServerCustom;
80 kj::Promise<void> construct(ConstructContext call_context)
override;
81 kj::Promise<void> makeEcho(MakeEchoContext call_context)
override;
94 #pragma GCC diagnostic pop
static bool getHas(S &&s)
ProxyServer< Message > Server
static bool getWant(S &&s)
static bool getWant(S &&s)
virtual std::unique_ptr< Echo > makeEcho()
#define S(a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p)
static bool getHas(S &&s)
ProxyClientMethodTraits< ipc::capnp::messages::Init::ConstructParams > M0
static void setWant(S &&s)
static void setWant(S &&s)
static void setHas(S &&s)
static bool getHas(S &&s)
ProxyClient< Message > Client
ProxyClientMethodTraits< ipc::capnp::messages::Init::MakeEchoParams > M1
static bool getWant(S &&s)
static void setHas(S &&s)
static void setHas(S &&s)
Initial interface created when a process is first started, and used to give and get access to other i...
static void setWant(S &&s)