Returns alphabetically sorted list of scalar functions available in Bolt, excluding companion functions.
| 312 | /// Returns alphabetically sorted list of scalar functions available in Bolt, |
| 313 | /// excluding companion functions. |
| 314 | std::vector<std::string> getSortedScalarNames() { |
| 315 | // Do not print "internal" functions. |
| 316 | static const std::unordered_set<std::string> kBlockList = {"row_constructor"}; |
| 317 | |
| 318 | auto functions = getFunctionSignatures(); |
| 319 | |
| 320 | std::vector<std::string> names; |
| 321 | names.reserve(functions.size()); |
| 322 | exec::aggregateFunctions().withRLock([&](const auto& aggregateFunctions) { |
| 323 | for (const auto& func : functions) { |
| 324 | const auto& name = func.first; |
| 325 | if (!isCompanionFunctionName(name, aggregateFunctions) && |
| 326 | kBlockList.count(name) == 0) { |
| 327 | names.emplace_back(name); |
| 328 | } |
| 329 | } |
| 330 | }); |
| 331 | std::sort(names.begin(), names.end()); |
| 332 | return names; |
| 333 | } |
| 334 | |
| 335 | /// Returns alphabetically sorted list of aggregate functions available in |
| 336 | /// Bolt, excluding compaion functions. |
no test coverage detected