MCPcopy Create free account
hub / github.com/LadybugDB/ladybug / toCypher

Method toCypher

src/function/scalar_macro_function.cpp:60–70  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

58}
59
60std::string ScalarMacroFunction::toCypher(const std::string& name) const {
61 std::vector<std::string> paramStrings;
62 for (auto& param : positionalArgs) {
63 paramStrings.push_back(param);
64 }
65 for (auto& defaultParam : defaultArgs) {
66 paramStrings.push_back(defaultParam.first + ":=" + defaultParam.second->toString());
67 }
68 return std::format("CREATE MACRO `{}` ({}) AS {};", name, StringUtils::join(paramStrings, ","),
69 expression->toString());
70}
71} // namespace function
72} // namespace lbug

Callers 2

bindFuncFunction · 0.45
bindFuncFunction · 0.45

Calls 3

joinFunction · 0.85
push_backMethod · 0.45
toStringMethod · 0.45

Tested by

no test coverage detected