Classes | |
struct | IEvalValue |
Dynamic expression evaluator. More... | |
class | EvalValuePtr |
Dynamic expression evaluator. More... | |
Functions | |
daq::StringPtr | getEval () const |
Gets the expression. More... | |
daq::BaseObjectPtr | getResult () const |
Gets the result of the expression. More... | |
daq::EvalValuePtr | cloneWithOwner (const daq::PropertyObjectPtr &owner) const |
Clones the object and attaches an owner. More... | |
void | getParseErrorCode () const |
Returns the parse error code. More... | |
daq::ListPtr< daq::IString > | getPropertyReferences () const |
Returns the names of all properties referenced by the eval value. More... | |
|
inline |
Clones the object and attaches an owner.
owner | The owner to attach to the cloned eval value. |
When the expression contains reference to some property object, then the expression cannot be evaluated unless an owner is attached to eval value. However, the object can be cloned with the specified owner attached. The client can then evaluate the cloned object.
|
inline |
Gets the expression.
Expression is passed as a parameter to the factory function.
|
inline |
Returns the parse error code.
When an eval value object is created, the expression is passed as an argument to the factory function. Parsing of the expression can fail, but the factory function will always succeed. Use this function to check if the parsing of the expression succeeded without evaluating the expression.
|
inline |
Returns the names of all properties referenced by the eval value.
Referenced properties are all occurrences matching the '"%" propref' pattern in the evaluation string.
|
inline |
Gets the result of the expression.
CalcFailedException | when calculation failed. |
OpendaqErrException | when reference resolution failed |
ParseFailedException | when expression parsing failed |
When this method is called for the first time, the object will trigger execution and return result.