#include <cpar.h>
Inheritance diagram for cDoubleExpression::

The actual expression should be supplied by creating a subclass and overriding evaluate(). The expression may use parameters stored in data members of the class; parameters can be initialized e.g. in the constructor.
Example:
class Expr12 : public cDoubleExpression {
private:
long p1;
cPar& p2;
public:
Expr12(long ap1, cPar& ap2) : p1(ap1), p2(ap2) {}
virtual double evaluate() {return 3*p1+p2;}
};
1.2.8.1 written by Dimitri van Heesch,
© 1997-2001