Kùzu C++ API
Loading...
Searching...
No Matches
bind_input.h
Go to the documentation of this file.
1
#pragma once
2
3
#include <vector>
4
5
#include "
cast.h
"
6
#include "
reader_config.h
"
7
#include "
value.h
"
8
9
namespace
kuzu
{
10
namespace
main {
11
class
ClientContext
;
12
}
13
14
namespace
function {
15
16
struct
TableFuncBindInput
{
17
std::vector<common::Value>
inputs
;
18
19
TableFuncBindInput
() =
default
;
20
EXPLICIT_COPY_DEFAULT_MOVE
(
TableFuncBindInput
);
21
virtual
~TableFuncBindInput
() =
default
;
22
23
template
<
class
TARGET>
24
const
TARGET*
constPtrCast
()
const
{
25
return
common::ku_dynamic_cast<const TableFuncBindInput*, const TARGET*>
(
this
);
26
}
27
28
protected
:
29
TableFuncBindInput
(
const
TableFuncBindInput
& other) :
inputs
{other.
inputs
} {}
30
};
31
32
struct
ScanTableFuncBindInput
final :
public
TableFuncBindInput
{
33
common::ReaderConfig
config
;
34
std::vector<std::string>
expectedColumnNames
;
35
std::vector<common::LogicalType>
expectedColumnTypes
;
36
main::ClientContext
*
context
;
37
38
explicit
ScanTableFuncBindInput
(
common::ReaderConfig
config
) :
config
{std::move(
config
)} {};
39
ScanTableFuncBindInput
(
common::ReaderConfig
config
,
40
std::vector<std::string>
expectedColumnNames
,
41
std::vector<common::LogicalType>
expectedColumnTypes
,
main::ClientContext
*
context
)
42
:
TableFuncBindInput
{},
config
{std::move(
config
)},
43
expectedColumnNames
{std::move(
expectedColumnNames
)},
44
expectedColumnTypes
{std::move(
expectedColumnTypes
)},
context
{
context
} {
45
inputs
.push_back(
common::Value::createValue
(this->config.
filePaths
[0]));
46
}
47
EXPLICIT_COPY_DEFAULT_MOVE
(
ScanTableFuncBindInput
);
48
49
private
:
50
ScanTableFuncBindInput
(
const
ScanTableFuncBindInput
& other)
51
:
TableFuncBindInput
{other},
config
{other.
config
.copy()},
52
expectedColumnNames
{other.
expectedColumnNames
},
53
expectedColumnTypes
{common::LogicalType::copy(other.
expectedColumnTypes
)},
54
context
{other.
context
} {}
55
};
56
57
}
// namespace function
58
}
// namespace kuzu
cast.h
kuzu::common::Value::createValue
static Value createValue(T)
Definition
value.h:223
kuzu::main::ClientContext
Contain client side configuration. We make profiler associated per query, so profiler is not maintain...
Definition
client_context.h:51
kuzu::common::ku_dynamic_cast
TO ku_dynamic_cast(FROM old)
Definition
cast.h:11
kuzu
Definition
alter_type.h:5
reader_config.h
kuzu::common::ReaderConfig
Definition
reader_config.h:33
kuzu::common::ReaderConfig::filePaths
std::vector< std::string > filePaths
Definition
reader_config.h:35
kuzu::function::ScanTableFuncBindInput
Definition
bind_input.h:32
kuzu::function::ScanTableFuncBindInput::EXPLICIT_COPY_DEFAULT_MOVE
EXPLICIT_COPY_DEFAULT_MOVE(ScanTableFuncBindInput)
kuzu::function::ScanTableFuncBindInput::ScanTableFuncBindInput
ScanTableFuncBindInput(common::ReaderConfig config, std::vector< std::string > expectedColumnNames, std::vector< common::LogicalType > expectedColumnTypes, main::ClientContext *context)
Definition
bind_input.h:39
kuzu::function::ScanTableFuncBindInput::config
common::ReaderConfig config
Definition
bind_input.h:33
kuzu::function::ScanTableFuncBindInput::ScanTableFuncBindInput
ScanTableFuncBindInput(common::ReaderConfig config)
Definition
bind_input.h:38
kuzu::function::ScanTableFuncBindInput::context
main::ClientContext * context
Definition
bind_input.h:36
kuzu::function::ScanTableFuncBindInput::expectedColumnNames
std::vector< std::string > expectedColumnNames
Definition
bind_input.h:34
kuzu::function::ScanTableFuncBindInput::expectedColumnTypes
std::vector< common::LogicalType > expectedColumnTypes
Definition
bind_input.h:35
kuzu::function::TableFuncBindInput
Definition
bind_input.h:16
kuzu::function::TableFuncBindInput::~TableFuncBindInput
virtual ~TableFuncBindInput()=default
kuzu::function::TableFuncBindInput::constPtrCast
const TARGET * constPtrCast() const
Definition
bind_input.h:24
kuzu::function::TableFuncBindInput::EXPLICIT_COPY_DEFAULT_MOVE
EXPLICIT_COPY_DEFAULT_MOVE(TableFuncBindInput)
kuzu::function::TableFuncBindInput::TableFuncBindInput
TableFuncBindInput()=default
kuzu::function::TableFuncBindInput::TableFuncBindInput
TableFuncBindInput(const TableFuncBindInput &other)
Definition
bind_input.h:29
kuzu::function::TableFuncBindInput::inputs
std::vector< common::Value > inputs
Definition
bind_input.h:17
value.h
headers
bind_input.h
Generated by
1.12.0