- Main Page
- Classes
- Files

- Alphabetical List
- Class List
- Class Hierarchy
- Class Members

# node_divide Class Reference

`#include <node_impl.hpp>`

Inheritance diagram for node_divide:

List of all members.

## Public Member Functions
| node_divide (node left, node right)
| node_divide (std::istream &stream)
## Private Member Functions
virtual void | print_node (std::ostream &stream, int indent) const
virtual double | evaluate_node () const
virtual void | save_node (std::ostream &stream) const

## Detailed Description

Division.

Definition at line 214 of file node_impl.hpp.

## Constructor & Destructor Documentation

node_divide::node_divide | ( | node | left,
|  | node | right |
| ) |  |  |

Definition at line 536 of file node_impl.cpp.

    00537 : node_binary(left, right)
    00538 {}

node_divide::node_divide | ( | std::istream & | stream | ) |

Definition at line 540 of file node_impl.cpp.

    00541 : node_binary(stream)
    00542 {}

## Member Function Documentation

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

Implements node_binary.

Definition at line 544 of file node_impl.cpp.

References node_binary::left(), node::print(), and node_binary::right().

    00546 {
    00547   stream << std::setw(indent) << "" << "/\n";
    00548   left().print(stream, indent + 2);
    00549   right().print(stream, indent + 2);
    00550 }

double node_divide::evaluate_node | ( |  | ) | const`[private, virtual]`

Implements node_binary.

Definition at line 552 of file node_impl.cpp.

References node_binary::evaluate_left(), and node_binary::evaluate_right().

    00554 {
    00555   return evaluate_left() / evaluate_right();
    00556 }

void node_divide::save_node | ( | std::ostream & | stream | ) | const`[private, virtual]`

Implements node_binary.

Definition at line 558 of file node_impl.cpp.

References node_binary::left(), node_binary::right(), and node::save().

    00560 {
    00561   stream << "divide ";
    00562   left().save(stream);
    00563   right().save(stream);
    00564 }

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

- node_impl.hpp
- node_impl.cpp