MCPcopy Create free account
hub / github.com/MaaXYZ/MaaFramework / add_context_sink

Function add_context_sink

source/binding/NodeJS/src/apis/server.cpp:48–53  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

46}
47
48static void add_context_sink(maajs::FunctionType func)
49{
50 auto ctx = std::make_unique<maajs::CallbackContext>(func, "ContextSink");
51 MaaAgentServerAddContextSink(ContextSink, ctx.get());
52 ExtContext::get(func.Env())->globalCallbacks.push_back(std::move(ctx));
53}
54
55static maajs::PromiseType start_up(maajs::EnvType env, std::string identifier)
56{

Callers

nothing calls this directly

Calls 4

moveFunction · 0.85
getMethod · 0.45
EnvMethod · 0.45

Tested by

no test coverage detected