amath  1.8.5
Simple command line calculator
ComplexiNode Class Reference

Use of the square root of -2 in a syntax tree. More...

#include <values.h>

Inheritance diagram for ComplexiNode:
Collaboration diagram for ComplexiNode:

Public Member Functions

 ComplexiNode ()
 
ReductionType GetReductionType ()
 
- Public Member Functions inherited from NumericValueNode
 NumericValueNode ()
 
 NumericValueNode (Number *value)
 
int GetPrecedence ()
 
char * GetText ()
 
SyntaxNodeGetNext ()
 
NumberEvaluate ()
 
void Attach (SyntaxNode *node)
 
void Detach (SyntaxNode *node)
 
void Replace (SyntaxNode *n, SyntaxNode *x)
 
void ReplaceWith (Number *value)
 
- Public Member Functions inherited from ExpressionNode
 ExpressionNode ()
 
 ExpressionNode (Number *value)
 
virtual ~ExpressionNode ()
 
NodeType GetNodeType ()
 
virtual bool IsSilent ()
 
char * GetTextCode ()
 
char * Execute ()
 
- Public Member Functions inherited from SyntaxNode
 SyntaxNode ()
 
virtual ~SyntaxNode ()
 
void SetFirstNode ()
 
bool GetFirstNode () const
 
SyntaxNodeGetParent () const
 
void SetParent (SyntaxNode *node)
 
virtual void ResetIterator ()
 

Protected Member Functions

char * GetNodeText ()
 

Additional Inherited Members

- Protected Attributes inherited from ExpressionNode
Numberresult
 
- Protected Attributes inherited from SyntaxNode
CharBufferoutput
 
SyntaxNodeparent
 
SyntaxNodeiterator
 
bool leftBottom
 

Detailed Description

Use of the square root of -2 in a syntax tree.

Definition at line 202 of file values.h.

Constructor & Destructor Documentation

◆ ComplexiNode()

ComplexiNode::ComplexiNode ( )

Definition at line 477 of file values.cpp.

References ComplexNumber::ComplexNumber(), and NumericValueNode::NumericValueNode().

Referenced by Parser::ParseAtomic().

477  :
478  NumericValueNode(new ComplexNumber(0.0, 1.0))
479 {
480 }
Represent a complex number with 2 components of 15 significant digits.
Definition: cplex.h:46
Here is the call graph for this function:
Here is the caller graph for this function:

Member Function Documentation

◆ GetNodeText()

char * ComplexiNode::GetNodeText ( )
protectedvirtual

Reimplemented from NumericValueNode.

Definition at line 487 of file values.cpp.

488 {
489  static char* ret = (char*)"i";
490  return ret;
491 }

◆ GetReductionType()

ReductionType ComplexiNode::GetReductionType ( )
virtual

Reimplemented from NumericValueNode.

Definition at line 482 of file values.cpp.

References nonereduc.

483 {
484  return nonereduc;
485 }

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