MCPcopy Create free account
hub / github.com/AGenUI/AGenUI / callSync

Method callSync

tests/cpp/support/mock_platform_function.h:26–41  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

24 const ::agenui::FunctionCallContext&, const std::string&)>;
25
26 ::agenui::FunctionCallResult callSync(
27 const ::agenui::FunctionCallContext& context,
28 const std::string& params) override {
29 {
30 std::lock_guard<std::mutex> lock(mutex_);
31 calls_.push_back({context, params});
32 }
33 ++callCount_;
34 if (handler_) {
35 return handler_(context, params);
36 }
37 ::agenui::FunctionCallResult res;
38 res.status = ::agenui::FunctionCallStatus::Success;
39 res.data = "{}";
40 return res;
41 }
42
43 void setHandler(CallSyncHandler handler) {
44 std::lock_guard<std::mutex> lock(mutex_);

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected