SeExpr

Public Member Functions | Public Attributes | Private Member Functions | Private Attributes | Friends | List of all members
SeExpr2::VarBlock Class Reference

A thread local evaluation context. Just allocate and fill in with data. More...

`#include <VarBlock.h>`

## Public Member Functions
| VarBlock (VarBlock &&other)
| Move semantics is the only allowed way to change the structure. More...
| ~VarBlock ()
| VarBlock (const VarBlock &)=delete
| Don't allow copying and operator='ing'. More...
VarBlock & | operator= (const VarBlock &)=delete
double *& | Pointer (uint32_t variableOffset)
| Get a reference to the data block pointer which can be modified. More...
char **& | CharPointer (uint32_t variableOffset)
char ** | data ()
| Raw data of the data block pointer (used by compiler) More...

## Public Attributes
int | indirectIndex
| indirect index to add to pointer based data More...
bool | threadSafe
| if true, interpreter's data will be copied to this instance before evaluation. More...
std::vector< double > | d
| copy of Interpreter's double data More...
std::vector< char * > | s
| copy of Interpreter's str data More...

## Private Member Functions
| VarBlock (int size, bool makeThreadSafe)
| Allocate an VarBlock. More...

## Private Attributes
std::vector< char * > | _dataPtrs
| This stores double* or char** ptrs to variables. More...

## Friends
class | VarBlockCreator

## Detailed Description

A thread local evaluation context. Just allocate and fill in with data.

Definition at line 33 of file VarBlock.h.

## Constructor & Destructor Documentation

## ◆ VarBlock() [1/3]

SeExpr2::VarBlock::VarBlock | ( | int | size,
|  | bool | makeThreadSafe
| ) |  |
| inline private

Allocate an VarBlock.

Definition at line 36 of file VarBlock.h.

## ◆ VarBlock() [2/3]

SeExpr2::VarBlock::VarBlock | ( | VarBlock && | other | ) |
| inline

Move semantics is the only allowed way to change the structure.

Definition at line 42 of file VarBlock.h.

References _dataPtrs, d, indirectIndex, s, and threadSafe.

## ◆ ~VarBlock()

SeExpr2::VarBlock::~VarBlock | ( |  | ) |
| inline

Definition at line 50 of file VarBlock.h.

## ◆ VarBlock() [3/3]

SeExpr2::VarBlock::VarBlock | ( | const VarBlock & |  | ) |
| delete

Don't allow copying and operator='ing'.

## Member Function Documentation

## ◆ CharPointer()

char**& SeExpr2::VarBlock::CharPointer | ( | uint32_t | variableOffset | ) |
| inline

Definition at line 58 of file VarBlock.h.

References _dataPtrs.

## ◆ data()

char** SeExpr2::VarBlock::data | ( |  | ) |
| inline

Raw data of the data block pointer (used by compiler)

Definition at line 74 of file VarBlock.h.

References _dataPtrs.

Referenced by SeExpr2::Interpreter::eval(), and SeExpr2::Expression::evalMultiple().

## ◆ operator=()

VarBlock& SeExpr2::VarBlock::operator= | ( | const VarBlock & |  | ) |
| delete

## ◆ Pointer()

double*& SeExpr2::VarBlock::Pointer | ( | uint32_t | variableOffset | ) |
| inline

Get a reference to the data block pointer which can be modified.

Definition at line 57 of file VarBlock.h.

References _dataPtrs.

Referenced by f().

## Friends And Related Function Documentation

## ◆ VarBlockCreator

friend class VarBlockCreator
| friend

Definition at line 39 of file VarBlock.h.

## Member Data Documentation

## ◆ _dataPtrs

std::vector<char*> SeExpr2::VarBlock::_dataPtrs
| private

This stores double* or char** ptrs to variables.

Definition at line 78 of file VarBlock.h.

Referenced by CharPointer(), data(), Pointer(), and VarBlock().

## ◆ d

std::vector<double> SeExpr2::VarBlock::d

copy of Interpreter's double data

Definition at line 68 of file VarBlock.h.

Referenced by SeExpr2::Interpreter::eval(), SeExpr2::Expression::evalFP(), and VarBlock().

## ◆ indirectIndex

int SeExpr2::VarBlock::indirectIndex

indirect index to add to pointer based data

Definition at line 62 of file VarBlock.h.

Referenced by SeExpr2::Interpreter::eval(), SeExpr2::Expression::evalMultiple(), and VarBlock().

## ◆ s

std::vector<char*> SeExpr2::VarBlock::s

copy of Interpreter's str data

Definition at line 71 of file VarBlock.h.

Referenced by SeExpr2::Interpreter::eval(), SeExpr2::Expression::evalStr(), and VarBlock().

## ◆ threadSafe

bool SeExpr2::VarBlock::threadSafe

if true, interpreter's data will be copied to this instance before evaluation.

Definition at line 65 of file VarBlock.h.

Referenced by SeExpr2::Interpreter::eval(), SeExpr2::Expression::evalFP(), SeExpr2::Expression::evalStr(), and VarBlock().

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

- /build/seexpr/src/SeExpr/src/SeExpr2/VarBlock.h