Extension function spec, used for complicated argument custom functions. More...
#include <SeExprFunc.h>
Public Member Functions | |
SeExprFuncX (const bool threadSafe) | |
virtual bool | prep (SeExprFuncNode *node, bool wantVec) |
virtual void | eval (const SeExprFuncNode *node, SeVec3d &result) const =0 |
virtual | ~SeExprFuncX () |
bool | isThreadSafe () const |
Private Attributes | |
bool | _threadSafe |
Extension function spec, used for complicated argument custom functions.
Provides the ability to handle all argument type checking and processing manually. Derive from this class and then make your own SeExprFunc that takes this object. This is necessary if you need string arguments or you have variable numbers of arguments. See SeExprBuiltins.h for some examples
Definition at line 24 of file SeExprFunc.h.
SeExprFuncX::SeExprFuncX | ( | const bool | threadSafe | ) | [inline] |
Create an SeExprFuncX. If the functions and type checking you implement is thread safe your derived class should call this with true. If not, then false. If you mark a function as thread unsafe, and it is used in an expression then bool SeExpression::isThreadSafe() will return false and the controlling software should not attempt to run multiple threads of an expression.
Definition at line 32 of file SeExprFunc.h.
virtual SeExprFuncX::~SeExprFuncX | ( | ) | [inline, virtual] |
Definition at line 42 of file SeExprFunc.h.
virtual void SeExprFuncX::eval | ( | const SeExprFuncNode * | node, | |
SeVec3d & | result | |||
) | const [pure virtual] |
evaluate the expression. the given node is where in the parse tree the evaluation is for
Implemented in SeExpr::CachedVoronoiFunc, SeExpr::CurveFuncX, SeExpr::CCurveFuncX, SeExpr::PrintFuncX, and SeExprEdExpression::DummyFuncX.
Referenced by SeExprFuncNode::eval().
bool SeExprFuncX::isThreadSafe | ( | ) | const [inline] |
Definition at line 44 of file SeExprFunc.h.
References _threadSafe.
Referenced by SeExprFuncNode::prep().
bool SeExprFuncX::prep | ( | SeExprFuncNode * | node, | |
bool | wantVec | |||
) | [virtual] |
prep the expression by doing all type checking argument checking, etc.
Reimplemented in SeExpr::CachedVoronoiFunc, SeExpr::CurveFuncX, SeExpr::CCurveFuncX, SeExpr::PrintFuncX, and SeExprEdExpression::DummyFuncX.
Definition at line 119 of file SeExprFunc.cpp.
Referenced by SeExprFuncNode::prep().
bool SeExprFuncX::_threadSafe [private] |
Definition at line 46 of file SeExprFunc.h.
Referenced by isThreadSafe().