Main Page | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members | Related Pages

mcAddSubOpHelpers Class Reference

#include <AddSubOp.h>

Inheritance diagram for mcAddSubOpHelpers:

Inheritance graph
[legend]
Collaboration diagram for mcAddSubOpHelpers:

Collaboration graph
[legend]
List of all members.

Detailed Description

A little class containing the DATA, MATH, GUI and IO sections of this element (as instances and not pointers).

This is entirely defined & implemented through macros.

Definition at line 53 of file AddSubOp.h.

Public Member Functions

 mcAddSubOpHelpers ()
virtual ~mcAddSubOpHelpers ()
bool data_isAddOp () const
bool data_isSubOp () const
bool math_CanBeApplied (const mcElement &, const mcElement &) const
 Returns TRUE if this operator can be applied on the two given elements.
mcRealValue math_Evaluate (mcRealValue v1, mcRealValue v2) const
 Applies the operator on the two given values and then returns it.
mcBasicOpRes math_ApplySimple (mcElement &m1, const mcElement &m2) const
 Works like #Apply but uses the mcElement::math_SimpleAdd/Mult/Div functions and thus does not take the pointer-to-pointer argument.
mcBasicOpRes math_Apply (mcElement &, const mcElement &, mcElement *) const
 Applies this operator on the left and right monomials.

Private Member Functions

 mcDEFINE_REFERENCE_DATA (mcAddSubOp, mdata_nType)


Constructor & Destructor Documentation

mcAddSubOpHelpers::mcAddSubOpHelpers  )  [inline]
 

Definition at line 58 of file AddSubOp.h.

virtual mcAddSubOpHelpers::~mcAddSubOpHelpers  )  [inline, virtual]
 

Definition at line 59 of file AddSubOp.h.


Member Function Documentation

bool mcAddSubOpHelpers::data_isAddOp  )  const [inline]
 

Definition at line 64 of file AddSubOp.h.

References mcET_ADDOP.

Referenced by math_Apply(), math_ApplySimple(), and math_Evaluate().

bool mcAddSubOpHelpers::data_isSubOp  )  const [inline]
 

Definition at line 65 of file AddSubOp.h.

References mcET_SUBOP.

mcBasicOpRes mcAddSubOpHelpers::math_Apply mcElement ,
const mcElement ,
mcElement
const [virtual]
 

Applies this operator on the left and right monomials.

Returns:
TRUE if the right monomial can be deleted.

Implements mcOperatorHelpers.

Definition at line 96 of file AddSubOp.cpp.

References data_isAddOp(), math_CanBeApplied(), and mcBOR_INVALID.

mcBasicOpRes mcAddSubOpHelpers::math_ApplySimple mcElement m1,
const mcElement m2
const [virtual]
 

Works like #Apply but uses the mcElement::math_SimpleAdd/Mult/Div functions and thus does not take the pointer-to-pointer argument.

Implements mcOperatorHelpers.

Definition at line 83 of file AddSubOp.cpp.

References data_isAddOp(), math_CanBeApplied(), mcBOR_INVALID, and mcBOR_REMOVE_OPERAND.

bool mcAddSubOpHelpers::math_CanBeApplied const mcElement ,
const mcElement
const [virtual]
 

Returns TRUE if this operator can be applied on the two given elements.

For non-commutative operators, the order is important: the first given pointer is the left operand while the second is the right one.

Implements mcOperatorHelpers.

Definition at line 80 of file AddSubOp.cpp.

Referenced by math_Apply(), and math_ApplySimple().

mcRealValue mcAddSubOpHelpers::math_Evaluate mcRealValue  v1,
mcRealValue  v2
const [virtual]
 

Applies the operator on the two given values and then returns it.

Implements mcOperatorHelpers.

Definition at line 104 of file AddSubOp.cpp.

References data_isAddOp().

mcAddSubOpHelpers::mcDEFINE_REFERENCE_DATA mcAddSubOp  ,
mdata_nType 
[private]
 


The documentation for this class was generated from the following files:

Documentation generated with Doxygen on Sun Feb 6 17:12:18 2005
Visit MathStudio home page for more info

[ Top ]