MCPcopy Create free account
hub / github.com/cinemast/libjson-rpc-cpp / main

Function main

src/examples/simpleclient.cpp:15–27  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

13using namespace std;
14
15int main() {
16 HttpClient client("http://localhost:8383");
17 Client c(client);
18
19 Json::Value params;
20 params["name"] = "Peter";
21
22 try {
23 cout << c.CallMethod("sayHello", params) << endl;
24 } catch (JsonRpcException &e) {
25 cerr << e.what() << endl;
26 }
27}

Callers

nothing calls this directly

Calls 2

CallMethodMethod · 0.80
whatMethod · 0.45

Tested by

no test coverage detected