Math Type Library (libmath++) 0.0.3
Public Member Functions | Protected Member Functions | List of all members
math::TBinaryNodeOp< T > Class Template Reference

#include <nodes.h>

Inheritance diagram for math::TBinaryNodeOp< T >:
math::TNode< T > math::TDivNode< T > math::TEquNode< T > math::TGreaterEquNode< T > math::TGreaterNode< T > math::TIfNode< T > math::TLessEquNode< T > math::TLessNode< T > math::TMulNode< T > math::TPlusNode< T > math::TPowNode< T > math::TUnEquNode< T >

Public Member Functions

virtual TNode< T > * left () const
 returns the right child node of the expression tree More...
 
virtual TNode< T > * right () const
 returns the left child node of the expression tree More...
 
virtual bool equals (const TNode< T > *ANode) const
 returns true, if given node equals to this one More...
 
- Public Member Functions inherited from math::TNode< T >
virtual ~TNode ()
 each virtual class needs a virtual destructor (this one does nothing)
 
TNodeType nodeType () const
 returns the type of this node
 
short priority () const
 returns the node priority
 
TNode< T > * parent () const
 returns the parent node (returns 0 if this node is the root node)
 
virtual TNode< T > * left () const
 returns the left child node (returns 0 if this node doesn't support one) More...
 
virtual TNode< T > * right () const
 returns the right child node (returns 0 if this node doesn't support one) More...
 
virtual void accept (TNodeVisitor< T > &)=0
 calls the visit method in TNodeVisitor<> More...
 
virtual TNode< T > * clone () const =0
 clones that node More...
 
iterator begin ()
 iterator access to the first value node in this operator level More...
 
iterator end ()
 iterator access to the end More...
 
virtual bool equals (const TNode< T > *ANode) const =0
 returns true, if given node equals to this one More...
 

Protected Member Functions

 TBinaryNodeOp (typename TBinaryNodeOp< T >::TNodeType AType, short APrio, TNode< T > *ALeft, TNode< T > *ARight)
 creates an binary operator node of type AType
 
- Protected Member Functions inherited from math::TNode< T >
 TNode (TNodeType ANodeType, short APriority, TNode< T > *AParentNode=0)
 initializes this node for given node type.
 
 TNode (const TNode< T > &n)
 
void parent (TNode< T > *AParent)
 initializes the parent node with the given one
 

Additional Inherited Members

- Public Types inherited from math::TNode< T >
enum  TNodeType {
  NUMBER_NODE , SYMBOL_NODE , PARAM_NODE , PLUS_NODE ,
  NEG_NODE , MUL_NODE , DIV_NODE , MOD_NODE ,
  POW_NODE , EQU_NODE , UNEQU_NODE , LESS_EQU_NODE ,
  GREATER_EQU_NODE , LESS_NODE , GREATER_NODE , FUNC_NODE ,
  SQRT_NODE , SIN_NODE , COS_NODE , TAN_NODE ,
  LN_NODE , IF_NODE
}
 
typedef TNodeIterator< T > iterator
 
typedef const TNodeIterator< T > const_iterator
 
typedef TOperandIter< TNode< T > > operand_iterator
 
typedef TOperandIter< const TNode< T > > const_operand_iterator
 

Detailed Description

template<typename T>
class math::TBinaryNodeOp< T >

TBinaryNodeOp<T> represents the base class for any binary operation node in the expression tree.

Definition at line 411 of file nodes.h.

Member Function Documentation

◆ equals()

template<typename T >
virtual bool math::TBinaryNodeOp< T >::equals ( const TNode< T > *  ANode) const
virtual

returns true, if given node equals to this one

Implements math::TNode< T >.

◆ left()

template<typename T >
virtual TNode< T > * math::TBinaryNodeOp< T >::left ( ) const
virtual

returns the right child node of the expression tree

Reimplemented from math::TNode< T >.

◆ right()

template<typename T >
virtual TNode< T > * math::TBinaryNodeOp< T >::right ( ) const
virtual

returns the left child node of the expression tree

Reimplemented from math::TNode< T >.


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