cPar::ExprElem Struct Reference

#include <cpar.h>

List of all members.


Detailed Description

One component in a (reversed Polish) expression in a cPar; see cPar::setDoubleValue(ExprElem *,int).


Public Member Functions

void operator= (int _i)
void operator= (short _i)
void operator= (long _l)
void operator= (double _d)
void operator= (cPar *_p)
void operator= (cPar &_r)
void operator= (MathFuncNoArg _f)
void operator= (MathFunc1Arg _f)
void operator= (MathFunc2Args _f)
void operator= (MathFunc3Args _f)
void operator= (MathFunc4Args _f)
void operator= (char _op)


Member Function Documentation

void cPar::ExprElem::operator= char  _op  )  [inline]
 

Operation.

During evaluation of the expression, two items (or three, with '?') are popped out of the stack, the given operator is applied to them and the result is pushed back on the stack.

The operation can be:

  • + - * / add, subtract, multiply, divide
  • % ^ modulo, power of
  • = ! equal, not equal
  • > } greater, greater or equal
  • < { less, less or equal
  • ? inline if (the C/C++ ?: operator)

void cPar::ExprElem::operator= MathFunc4Args  _f  )  [inline]
 

The argument can be a pointer to a function that takes 4 double arguments and returns a double.

Effect during evaluation of the expression: 4 doubles are popped from the stack, the given function is called with them as arguments, and the return value is pushed back on the stack. See also the cFunctionType class and the Define_Function() macro.

The OMNeT++ functions generating random variables of different distributions can also be used in ExprElem expressions.

void cPar::ExprElem::operator= MathFunc3Args  _f  )  [inline]
 

The argument can be a pointer to a function that takes 3 double arguments and returns a double.

Effect during evaluation of the expression: 3 doubles are popped from the stack, the given function is called with them as arguments, and the return value is pushed back on the stack. See also the cFunctionType class and the Define_Function() macro.

The OMNeT++ functions generating random variables of different distributions can also be used in ExprElem expressions.

void cPar::ExprElem::operator= MathFunc2Args  _f  )  [inline]
 

The argument can be a pointer to a function that takes 2 double arguments and returns a double.

Effect during evaluation of the expression: 2 doubles are popped from the stack, the given function is called with them as arguments, and the return value is pushed back on the stack. See also the cFunctionType class and the Define_Function() macro.

The OMNeT++ functions generating random variables of different distributions can also be used in ExprElem expressions.

void cPar::ExprElem::operator= MathFunc1Arg  _f  )  [inline]
 

The argument can be a pointer to a function that takes 1 double argument and returns a double (e.g.

sqrt()). Effect during evaluation of the expression: 1 double is popped from the stack, the given function is called with them as arguments, and the return value is pushed back on the stack. See also the cFunctionType class and the Define_Function() macro.

The OMNeT++ functions generating random variables of different distributions can also be used in ExprElem expressions.

void cPar::ExprElem::operator= MathFuncNoArg  _f  )  [inline]
 

The argument can be a pointer to a function that takes no arguments and returns a double.

Effect during evaluation of the expression: the return value is pushed on the stack. See also the cFunctionType class and the Define_Function() macro.

The OMNeT++ functions generating random variables of different distributions can also be used in ExprElem expressions.

void cPar::ExprElem::operator= cPar _r  )  [inline]
 

Effect during evaluation of the expression: takes the value of the cPar object (a double) and pushes the value on the evaluation stack.

The cPar which evaluates this expression will copy the cPar for itself.

void cPar::ExprElem::operator= cPar _p  )  [inline]
 

Effect during evaluation of the expression: takes the value of the cPar object (a double) and pushes the value on the evaluation stack.

The cPar is an "external" one: its ownership does not change. This is how NED-language REF parameters in expressions are handled.

void cPar::ExprElem::operator= double  _d  )  [inline]
 

Effect during evaluation of the expression: pushes the given number (which is converted to double) on the evaluation stack.

void cPar::ExprElem::operator= long  _l  )  [inline]
 

Effect during evaluation of the expression: pushes the given number (which is converted to double) on the evaluation stack.

void cPar::ExprElem::operator= short  _i  )  [inline]
 

Effect during evaluation of the expression: pushes the given number (which is converted to double) on the evaluation stack.

void cPar::ExprElem::operator= int  _i  )  [inline]
 

Effect during evaluation of the expression: pushes the given number (which is converted to double) on the evaluation stack.


The documentation for this struct was generated from the following file:
Generated on Sat Oct 21 17:47:57 2006 for OMNeT++/OMNEST Simulation Library by  doxygen 1.4.6