node_number Class Reference

#include <node_impl.hpp>

Inheritance diagram for node_number:

node_impl

List of all members.

Public Member Functions

 node_number (double value)
double value () const

Private Member Functions

virtual void print_node (std::ostream &stream, int indent) const
virtual double evaluate_node () const

Private Attributes

double value_


Detailed Description

Number data type. Used for numeric literals.

Definition at line 62 of file node_impl.hpp.


Constructor & Destructor Documentation

node_number::node_number ( double  value  ) 

Definition at line 93 of file node_impl.cpp.

00094 : node_impl(), value_(value)
00095 {}


Member Function Documentation

double node_number::value (  )  const

Definition at line 97 of file node_impl.cpp.

References value_.

Referenced by evaluate_node(), and print_node().

00099 {
00100   return value_;
00101 }

void node_number::print_node ( std::ostream &  stream,
int  indent 
) const [private, virtual]

Implements node_impl.

Definition at line 103 of file node_impl.cpp.

References value().

00105 {
00106   stream << std::setw(indent) << "" << value() << '\n';
00107 }

double node_number::evaluate_node (  )  const [private, virtual]

Implements node_impl.

Definition at line 109 of file node_impl.cpp.

References value().

00111 {
00112   return value();
00113 }


Member Data Documentation

double node_number::value_ [private]

Definition at line 70 of file node_impl.hpp.

Referenced by value().


The documentation for this class was generated from the following files:
Generated on Sun Nov 30 10:05:28 2008 for Calculator by  doxygen 1.5.3