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

Function GetKernels

cpp/src/arrow/acero/aggregate_internal.cc:109–122  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

107}
108
109Result<std::vector<const HashAggregateKernel*>> GetKernels(
110 ExecContext* ctx, const std::vector<Aggregate>& aggregates,
111 const std::vector<std::vector<TypeHolder>>& in_types) {
112 if (aggregates.size() != in_types.size()) {
113 return Status::Invalid(aggregates.size(), " aggregate functions were specified but ",
114 in_types.size(), " arguments were provided.");
115 }
116
117 std::vector<const HashAggregateKernel*> kernels(in_types.size());
118 for (size_t i = 0; i < aggregates.size(); ++i) {
119 ARROW_ASSIGN_OR_RAISE(kernels[i], GetKernel(ctx, aggregates[i], in_types[i]));
120 }
121 return kernels;
122}
123
124Result<std::vector<std::unique_ptr<KernelState>>> InitKernels(
125 const std::vector<const HashAggregateKernel*>& kernels, ExecContext* ctx,

Callers

nothing calls this directly

Calls 4

GetKernelFunction · 0.85
ARROW_ASSIGN_OR_RAISEFunction · 0.70
InvalidFunction · 0.50
sizeMethod · 0.45

Tested by

no test coverage detected