amath
1.8.5
Simple command line calculator
|
#include <operators.h>
Public Member Functions | |
FactorialNode (ExpressionNode *expression) | |
~FactorialNode () | |
char * | GetText () |
Number * | Evaluate () |
int | GetPrecedence () |
SyntaxNode * | GetNext () |
void | Attach (SyntaxNode *node) |
void | Detach (SyntaxNode *node) |
void | Replace (SyntaxNode *n, SyntaxNode *x) |
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 |
SyntaxNode * | GetParent () const |
void | SetParent (SyntaxNode *node) |
virtual ReductionType | GetReductionType () |
virtual void | ResetIterator () |
Protected Member Functions | |
char * | GetNodeText () |
Private Attributes | |
ExpressionNode * | expression |
Additional Inherited Members | |
Protected Attributes inherited from ExpressionNode | |
Number * | result |
Protected Attributes inherited from SyntaxNode | |
CharBuffer * | output |
SyntaxNode * | parent |
SyntaxNode * | iterator |
bool | leftBottom |
Definition at line 85 of file operators.h.
FactorialNode::FactorialNode | ( | ExpressionNode * | expression | ) |
Definition at line 224 of file operators.cpp.
References expression, and ExpressionNode::ExpressionNode().
Referenced by Parser::ParseAtomic().
FactorialNode::~FactorialNode | ( | ) |
|
virtual |
Implements SyntaxNode.
Definition at line 278 of file operators.cpp.
References expression, and SyntaxNode::SetParent().
|
virtual |
|
virtual |
Implements ExpressionNode.
Definition at line 255 of file operators.cpp.
References ExpressionNode::Evaluate(), expression, Number::Factorial(), and ExpressionNode::result.
|
virtual |
Implements SyntaxNode.
Definition at line 267 of file operators.cpp.
References expression, and SyntaxNode::iterator.
|
protectedvirtual |
Implements ExpressionNode.
Definition at line 261 of file operators.cpp.
Referenced by GetText().
|
virtual |
|
virtual |
Implements ExpressionNode.
Definition at line 237 of file operators.cpp.
References CharBuffer::Append(), CharBuffer::Empty(), CharBuffer::EnsureSize(), expression, GetNodeText(), CharBuffer::GetString(), ExpressionNode::GetText(), SyntaxNode::output, and StrLen().
|
virtual |
|
private |
Definition at line 103 of file operators.h.
Referenced by Attach(), Detach(), Evaluate(), FactorialNode(), GetNext(), GetText(), Replace(), and ~FactorialNode().