vkdb
A time series database engine in C++.
Loading...
Searching...
No Matches
vkdb::Interpreter Class Reference

Interpreter for vq. More...

#include <interpreter.h>

Public Types

using error_callback = std::function<void(const RuntimeError&)>
 

Public Member Functions

 Interpreter (Database &database, error_callback callback=[](const RuntimeError &) {}) noexcept
 Construct a new Interpreter object.
 
void interpret (const Expr &expr, std::ostream &stream=std::cout) const noexcept
 Interpret the expression.
 

Detailed Description

Interpreter for vq.

Definition at line 261 of file interpreter.h.

Member Typedef Documentation

◆ error_callback

using vkdb::Interpreter::error_callback = std::function<void(const RuntimeError&)>

Definition at line 263 of file interpreter.h.

Constructor & Destructor Documentation

◆ Interpreter()

vkdb::Interpreter::Interpreter ( Database & database,
error_callback callback = [](const RuntimeError&) {} )
explicitnoexcept

Construct a new Interpreter object.

Defaults the callback to an empty lambda.

Parameters
databaseDatabase.
callbackError callback.

Definition at line 16 of file interpreter.cpp.

Member Function Documentation

◆ interpret()

void vkdb::Interpreter::interpret ( const Expr & expr,
std::ostream & stream = std::cout ) const
noexcept

Interpret the expression.

Defaults the output stream to std::cout.

Parameters
exprExpression.
streamStream.

Definition at line 19 of file interpreter.cpp.


The documentation for this class was generated from the following files: