Kùzu C++ API
Loading...
Searching...
No Matches
const_function_executor.h
Go to the documentation of this file.
1#pragma once
2
3#include "value_vector.h"
4
5namespace kuzu {
6namespace function {
7
9
10 template<typename RESULT_TYPE, typename OP>
11 static void execute(common::ValueVector& result) {
12 KU_ASSERT(result.state->isFlat());
13 auto resultValues = (RESULT_TYPE*)result.getData();
14 auto idx = result.state->getSelVector()[0];
15 KU_ASSERT(idx == 0);
16 OP::operation(resultValues[idx]);
17 }
18};
19
20} // namespace function
21} // namespace kuzu
#define KU_ASSERT(condition)
Definition assert.h:19
Definition value_vector.h:20
uint8_t * getData() const
Definition value_vector.h:83
std::shared_ptr< DataChunkState > state
Definition value_vector.h:106
Definition array_utils.h:7
Definition const_function_executor.h:8
static void execute(common::ValueVector &result)
Definition const_function_executor.h:11