LSBBExpression Class

class localsolverblackbox::LSBBExpression

Mathematical modeling expression.

Expressions are used to build the mathematical optimization model associated to LocalSolverBlackBox. An expression is composed of an operator (which corresponds to its type) and its operands (which are other expressions of the model).

See:LSBBModel
See:LSBBOperator

Summary

Functions
addOperand Adds the given operand to this expression.
isBool Returns true if this expression is a boolean (ie 0 or 1), false otherwise.
isInt Returns true if this expression is an integer, false otherwise.
isDouble Returns true if this expression is a double, false otherwise.

Functions

void addOperand(LSBBExpression e)

Adds the given operand to this expression.

Only allowed in state S_Modeling.

Parameters:e - Operand to add.

bool isBool()

Returns true if this expression is a boolean (ie 0 or 1), false otherwise.

Only allowed in states S_Paused or S_Stopped.

Return:True if the expression is a boolean.

bool isInt()

Returns true if this expression is an integer, false otherwise.

Only allowed in states S_Paused or S_Stopped. Note that a boolean is also an integer.

Return:True if the expression is an integer.

bool isDouble()

Returns true if this expression is a double, false otherwise.

Only allowed in states S_Paused or S_Stopped.

Return:True if the expression is a double.