Kuzu C++ API
Loading...
Searching...
No Matches
prepared_statement_manager.h
Go to the documentation of this file.
1#pragma once
2
3#include <memory>
4#include <mutex>
5#include <unordered_map>
6
7namespace kuzu {
8namespace main {
9
11
13public:
16
17 std::string addStatement(std::unique_ptr<CachedPreparedStatement> statement);
18
19 bool containsStatement(const std::string& name) const { return statementMap.contains(name); }
20
21 CachedPreparedStatement* getCachedStatement(const std::string& name) const;
22
23private:
24 std::mutex mtx;
25 uint32_t currentIdx = 0;
26 std::unordered_map<std::string, std::unique_ptr<CachedPreparedStatement>> statementMap;
27};
28
29} // namespace main
30} // namespace kuzu
CachedPreparedStatement * getCachedStatement(const std::string &name) const
bool containsStatement(const std::string &name) const
Definition prepared_statement_manager.h:19
std::string addStatement(std::unique_ptr< CachedPreparedStatement > statement)
Definition bind_input.h:16
Definition array_utils.h:7
Definition prepared_statement.h:22