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

Method Init

cpp/src/arrow/compute/kernels/codegen_internal.h:79–87  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

77 explicit OptionsWrapper(OptionsType options) : options(std::move(options)) {}
78
79 static Result<std::unique_ptr<KernelState>> Init(KernelContext* ctx,
80 const KernelInitArgs& args) {
81 if (auto options = static_cast<const OptionsType*>(args.options)) {
82 return std::make_unique<OptionsWrapper>(*options);
83 }
84
85 return Status::Invalid(
86 "Attempted to initialize KernelState from null FunctionOptions");
87 }
88
89 static const OptionsType& Get(const KernelState& state) {
90 return ::arrow::internal::checked_cast<const OptionsWrapper&>(state).options;

Callers

nothing calls this directly

Calls 1

InvalidFunction · 0.50

Tested by

no test coverage detected