igor::iNodeVisitorPrintTree Class Reference

#include <iNodeVisitorPrintTree.h>

Inherits igor::iNodeVisitor.

Public Member Functions

 iNodeVisitorPrintTree (bool brief=true)
 
virtual ~iNodeVisitorPrintTree ()=default
 
void printToConsole (iNodePtr node)
 
- Public Member Functions inherited from igor::iNodeVisitor
 iNodeVisitor ()=default
 
virtual ~iNodeVisitor ()=default
 
void setTraverseInactiveChildren (bool traverseInactive=true)
 
void setTraverseSiblings (bool traverseSiblings=true)
 
void traverseTree (iNodePtr node)
 

Protected Member Functions

void preTraverse () override
 
bool preOrderVisit (iNodePtr node, iNodePtr nextSibling) override
 
void preLine ()
 
void postOrderVisit (iNodePtr node) override
 
void postTraverse () override
 
virtual void preTraverse ()=0
 
virtual bool preOrderVisit (iNodePtr node, iNodePtr nextSibling)=0
 
virtual void postOrderVisit (iNodePtr node)=0
 
virtual void postTraverse ()=0
 

Detailed Description

traveses node tree and prints basic information in to console

Constructor & Destructor Documentation

◆ iNodeVisitorPrintTree()

igor::iNodeVisitorPrintTree::iNodeVisitorPrintTree ( bool  brief = true)

initializes traversal config

Parameters
briefif true only a brief node info will be extracted

◆ ~iNodeVisitorPrintTree()

virtual igor::iNodeVisitorPrintTree::~iNodeVisitorPrintTree ( )
virtualdefault

does nothing

Member Function Documentation

◆ postOrderVisit()

void igor::iNodeVisitorPrintTree::postOrderVisit ( iNodePtr  node)
overrideprotectedvirtual

handles output indentation

Implements igor::iNodeVisitor.

◆ postTraverse()

void igor::iNodeVisitorPrintTree::postTraverse ( )
overrideprotectedvirtual

some more output

Implements igor::iNodeVisitor.

◆ preLine()

void igor::iNodeVisitorPrintTree::preLine ( )
protected

◆ preOrderVisit()

bool igor::iNodeVisitorPrintTree::preOrderVisit ( iNodePtr  node,
iNodePtr  nextSibling 
)
overrideprotectedvirtual

generates information string on every node passed by handles output indentation

Parameters
nodecurrent node

Implements igor::iNodeVisitor.

◆ preTraverse()

void igor::iNodeVisitorPrintTree::preTraverse ( )
overrideprotectedvirtual

initialisation

Implements igor::iNodeVisitor.

◆ printToConsole()

void igor::iNodeVisitorPrintTree::printToConsole ( iNodePtr  node)

traverses the tree and prints the output in console


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