MCPcopy Create free account
hub / github.com/apache/arrow / DecodeOption

Function DecodeOption

cpp/src/arrow/engine/substrait/expression_internal.cc:108–119  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

106}
107
108Status DecodeOption(const substrait::FunctionOption& opt, SubstraitCall* call) {
109 std::vector<std::string_view> prefs;
110 if (opt.preference_size() == 0) {
111 return Status::Invalid("Invalid Substrait plan. The option ", opt.name(),
112 " is specified but does not list any choices");
113 }
114 for (const auto& preference : opt.preference()) {
115 prefs.push_back(preference);
116 }
117 call->SetOption(opt.name(), prefs);
118 return Status::OK();
119}
120
121Result<SubstraitCall> DecodeScalarFunction(
122 Id id, const substrait::Expression::ScalarFunction& scalar_fn,

Callers 2

DecodeScalarFunctionFunction · 0.85
FromProtoFunction · 0.85

Calls 5

push_backMethod · 0.80
SetOptionMethod · 0.80
InvalidFunction · 0.50
OKFunction · 0.50
nameMethod · 0.45

Tested by

no test coverage detected