| TerraLib 4.1

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files
- Examples

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Types | Public Member Functions | Public Attributes
TeREDBLACK::TeRedBlackNode< T > Class Template Reference

Template class for nodes in a Red-Black tree. More...

`#include <TeRedBlackTree.h>`

List of all members.

## Public Types

typedef T | TeRedBlackNodeData
| Export node's data type.

## Public Member Functions

| TeRedBlackNode (const TeRBNodeColor &color=TeREDNODE)
| Constructor.
| TeRedBlackNode (T &d, const TeRBNodeColor &color=TeREDNODE)
| Constructor.

## Public Attributes

T | data_
| Node's data.
TeRedBlackNode * | left_
| Pointer to the left sub-tree.
TeRedBlackNode * | right_
| Pointer to the right sub-tree.
TeRedBlackNode * | parent_
| Pointeir to the father's node.
TeRBNodeColor | color_
| Node's color (RED or BLACK).

## Detailed Description

### template<class T>
class TeREDBLACK::TeRedBlackNode< T >

Template class for nodes in a Red-Black tree.

This class contains the common attributes to a node used by a binary tree. Only used for commom binary trees, if you want a more sophisticated tree, you can continue using the Red-Black Tree framework defined below, it is possible taking care of some default attributes that a node must have to implement (left_, right_, parent_, data_).

## Member Typedef Documentation

template<class T >

typedef T TeREDBLACK::TeRedBlackNode< T >::TeRedBlackNodeData

Export node's data type.

## Constructor & Destructor Documentation

template<class T >

TeREDBLACK::TeRedBlackNode< T >::TeRedBlackNode | ( | const TeRBNodeColor & | color = `TeREDNODE` | ) | `[inline]`

Constructor.

template<class T >

TeREDBLACK::TeRedBlackNode< T >::TeRedBlackNode | ( | T & | d,
|  | const TeRBNodeColor & | color = `TeREDNODE`
| ) |  | `[inline]`

Constructor.

## Member Data Documentation

template<class T >

TeRBNodeColor TeREDBLACK::TeRedBlackNode< T >::color_

Node's color (RED or BLACK).

template<class T >

T TeREDBLACK::TeRedBlackNode< T >::data_

Node's data.

template<class T >

TeRedBlackNode* TeREDBLACK::TeRedBlackNode< T >::left_

Pointer to the left sub-tree.

template<class T >

TeRedBlackNode* TeREDBLACK::TeRedBlackNode< T >::parent_

Pointeir to the father's node.

template<class T >

TeRedBlackNode* TeREDBLACK::TeRedBlackNode< T >::right_

Pointer to the right sub-tree.

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

- E:/Projetos_Primeiro_Semestre_2012/TerraView/terralib/src/terralib/kernel/TeRedBlackTree.h

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines