VTK
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
vtkHyperTreeGridCursor Class Reference

Objects for depth-first traversal HyperTreeGrids. More...

#include <vtkHyperTreeGridCursor.h>

Inheritance diagram for vtkHyperTreeGridCursor:
[legend]
Collaboration diagram for vtkHyperTreeGridCursor:
[legend]

Public Types

typedef vtkHyperTreeCursor Superclass
 
- Public Types inherited from vtkHyperTreeCursor
typedef vtkObject Superclass
 

Public Member Functions

virtual vtkTypeBool IsA (const char *type)
 Return 1 if this class is the same type of (or a subclass of) the named class. More...
 
vtkHyperTreeGridCursorNewInstance () const
 
void PrintSelf (ostream &os, vtkIndent indent) override
 Methods invoked by print to print information about the object including superclasses. More...
 
vtkHyperTreeGridCursorClone () override
 Create a copy of `this'. More...
 
virtual void Initialize (vtkHyperTreeGrid *, vtkIdType)
 Initialize cursor at root of given tree index in grid. More...
 
vtkIdType GetVertexId () override
 Return the index of the current vertex in the tree. More...
 
virtual vtkIdType GetGlobalNodeIndex ()
 Return the global index (relative to the grid) of the current vertex in the tree. More...
 
bool IsLeaf () override
 Is the cursor pointing to a leaf? More...
 
bool IsRoot () override
 Is the cursor at tree root? More...
 
unsigned int GetLevel () override
 Get the level of the tree vertex pointed by the cursor. More...
 
int GetChildIndex () override
 Return the child number of the current vertex relative to its parent. More...
 
void ToRoot () override
 Move the cursor to the root vertex. More...
 
void ToParent () override
 Move the cursor to the parent of the current vertex. More...
 
void ToChild (int child) override
 Move the cursor to child `child' of the current vertex. More...
 
void ToSameVertex (vtkHyperTreeCursor *vtkNotUsed(other)) override
 Move the cursor to the same vertex pointed by `other'. More...
 
bool IsEqual (vtkHyperTreeCursor *vtkNotUsed(other)) override
 Is `this' equal to `other'? More...
 
int SameTree (vtkHyperTreeCursor *vtkNotUsed(other)) override
 Are `this' and `other' pointing on the same hypertree? More...
 
int GetNumberOfChildren () override
 Return the number of children for each node (non-vertex leaf) of the tree. More...
 
int GetDimension () override
 Return the dimension of the tree. More...
 
virtual doubleGetOrigin ()
 Compute the origin of the cursor. More...
 
virtual doubleGetSize ()
 Compute the size of the cursor. More...
 
virtual void GetBounds (double pt[6])
 Compute the bounds of the cursor. More...
 
virtual void GetPoint (double pt[3])
 Compute the center coordinates of the cursor. More...
 
virtual unsigned int GetNumberOfCursors ()
 Return the number of neighborhood cursors The neighborhood definition depends on the type of cursor. More...
 
virtual vtkHyperTreeGridCursorGetCursor (unsigned int)
 Return the cursor pointing into i-th neighbor. More...
 
virtual bool GetCornerCursors (unsigned int, unsigned int, vtkIdList *)
 Return the list of cursors pointing to the leaves touching a given corner of the cell. More...
 
virtual void SetGrid (vtkHyperTreeGrid *)
 Set the hyper tree grid to which the cursor is pointing. More...
 
virtual vtkHyperTreeGridGetGrid ()
 Set the hyper tree grid to which the cursor is pointing. More...
 
void SetTree (vtkHyperTree *) override
 Set the hyper tree to which the cursor is pointing. More...
 
vtkHyperTreeGetTree () override
 Set the hyper tree to which the cursor is pointing. More...
 
- Public Member Functions inherited from vtkHyperTreeCursor
vtkHyperTreeCursorNewInstance () const
 
virtual void ToSameVertex (vtkHyperTreeCursor *other)=0
 Move the cursor to the same vertex pointed by `other'. More...
 
virtual bool IsEqual (vtkHyperTreeCursor *other)=0
 Is `this' equal to `other'? More...
 
virtual int SameTree (vtkHyperTreeCursor *other)=0
 Are `this' and `other' pointing on the same hypertree? More...
 
- Public Member Functions inherited from vtkObject
 vtkBaseTypeMacro (vtkObject, vtkObjectBase)
 
virtual void DebugOn ()
 Turn debugging output on. More...
 
virtual void DebugOff ()
 Turn debugging output off. More...
 
bool GetDebug ()
 Get the value of the debug flag. More...
 
void SetDebug (bool debugFlag)
 Set the value of the debug flag. More...
 
virtual void Modified ()
 Update the modification time for this object. More...
 
virtual vtkMTimeType GetMTime ()
 Return this object's modified time. More...
 
void RemoveObserver (unsigned long tag)
 
void RemoveObservers (unsigned long event)
 
void RemoveObservers (const char *event)
 
void RemoveAllObservers ()
 
vtkTypeBool HasObserver (unsigned long event)
 
vtkTypeBool HasObserver (const char *event)
 
int InvokeEvent (unsigned long event)
 
int InvokeEvent (const char *event)
 
unsigned long AddObserver (unsigned long event, vtkCommand *, float priority=0.0f)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
unsigned long AddObserver (const char *event, vtkCommand *, float priority=0.0f)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
vtkCommandGetCommand (unsigned long tag)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
void RemoveObserver (vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
void RemoveObservers (unsigned long event, vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
void RemoveObservers (const char *event, vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
vtkTypeBool HasObserver (unsigned long event, vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
vtkTypeBool HasObserver (const char *event, vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
template<class U , class T >
unsigned long AddObserver (unsigned long event, U observer, void(T::*callback)(), float priority=0.0f)
 Overloads to AddObserver that allow developers to add class member functions as callbacks for events. More...
 
template<class U , class T >
unsigned long AddObserver (unsigned long event, U observer, void(T::*callback)(vtkObject *, unsigned long, void *), float priority=0.0f)
 Overloads to AddObserver that allow developers to add class member functions as callbacks for events. More...
 
template<class U , class T >
unsigned long AddObserver (unsigned long event, U observer, bool(T::*callback)(vtkObject *, unsigned long, void *), float priority=0.0f)
 Allow user to set the AbortFlagOn() with the return value of the callback method. More...
 
int InvokeEvent (unsigned long event, void *callData)
 This method invokes an event and return whether the event was aborted or not. More...
 
int InvokeEvent (const char *event, void *callData)
 This method invokes an event and return whether the event was aborted or not. More...
 
- Public Member Functions inherited from vtkObjectBase
const char * GetClassName () const
 Return the class name as a string. More...
 
virtual void Delete ()
 Delete a VTK object. More...
 
virtual void FastDelete ()
 Delete a reference to this object. More...
 
void InitializeObjectBase ()
 
void Print (ostream &os)
 Print an object to an ostream. More...
 
virtual void Register (vtkObjectBase *o)
 Increase the reference count (mark as used by another object). More...
 
virtual void UnRegister (vtkObjectBase *o)
 Decrease the reference count (release by another object). More...
 
int GetReferenceCount ()
 Return the current reference count of this object. More...
 
void SetReferenceCount (int)
 Sets the reference count. More...
 
void PrintRevisions (ostream &)
 Legacy. More...
 
virtual void PrintHeader (ostream &os, vtkIndent indent)
 Methods invoked by print to print information about the object including superclasses. More...
 
virtual void PrintTrailer (ostream &os, vtkIndent indent)
 Methods invoked by print to print information about the object including superclasses. More...
 

Static Public Member Functions

static vtkTypeBool IsTypeOf (const char *type)
 
static vtkHyperTreeGridCursorSafeDownCast (vtkObjectBase *o)
 
static vtkHyperTreeGridCursorNew ()
 
- Static Public Member Functions inherited from vtkHyperTreeCursor
static vtkTypeBool IsTypeOf (const char *type)
 
static vtkHyperTreeCursorSafeDownCast (vtkObjectBase *o)
 
- Static Public Member Functions inherited from vtkObject
static vtkObjectNew ()
 Create an object with Debug turned off, modified time initialized to zero, and reference counting on. More...
 
static void BreakOnError ()
 This method is called when vtkErrorMacro executes. More...
 
static void SetGlobalWarningDisplay (int val)
 This is a global flag that controls whether any debug, warning or error messages are displayed. More...
 
static void GlobalWarningDisplayOn ()
 This is a global flag that controls whether any debug, warning or error messages are displayed. More...
 
static void GlobalWarningDisplayOff ()
 This is a global flag that controls whether any debug, warning or error messages are displayed. More...
 
static int GetGlobalWarningDisplay ()
 This is a global flag that controls whether any debug, warning or error messages are displayed. More...
 
- Static Public Member Functions inherited from vtkObjectBase
static vtkTypeBool IsTypeOf (const char *name)
 Return 1 if this class type is the same type of (or a subclass of) the named class. More...
 
static vtkObjectBaseNew ()
 Create an object with Debug turned off, modified time initialized to zero, and reference counting on. More...
 

Protected Member Functions

virtual vtkObjectBaseNewInstanceInternal () const
 
 vtkHyperTreeGridCursor ()
 Constructor. More...
 
 ~vtkHyperTreeGridCursor () override
 Destructor. More...
 
- Protected Member Functions inherited from vtkHyperTreeCursor
 vtkHyperTreeCursor ()
 
 ~vtkHyperTreeCursor () override
 
- Protected Member Functions inherited from vtkObject
 vtkObject ()
 
 ~vtkObject () override
 
void RegisterInternal (vtkObjectBase *, vtkTypeBool check) override
 
void UnRegisterInternal (vtkObjectBase *, vtkTypeBool check) override
 
void InternalGrabFocus (vtkCommand *mouseEvents, vtkCommand *keypressEvents=nullptr)
 These methods allow a command to exclusively grab all events. More...
 
void InternalReleaseFocus ()
 These methods allow a command to exclusively grab all events. More...
 
- Protected Member Functions inherited from vtkObjectBase
 vtkObjectBase ()
 
virtual ~vtkObjectBase ()
 
virtual void CollectRevisions (ostream &)
 
virtual void ReportReferences (vtkGarbageCollector *)
 
 vtkObjectBase (const vtkObjectBase &)
 
void operator= (const vtkObjectBase &)
 

Protected Attributes

vtkHyperTreeGridGrid
 
vtkHyperTreeTree
 
unsigned int Level
 
vtkIdType Index
 
bool Leaf
 
- Protected Attributes inherited from vtkObject
bool Debug
 
vtkTimeStamp MTime
 
vtkSubjectHelper * SubjectHelper
 
- Protected Attributes inherited from vtkObjectBase
vtkAtomicInt32 ReferenceCount
 
vtkWeakPointerBase ** WeakPointers
 

Detailed Description

Objects for depth-first traversal HyperTreeGrids.

Objects that can perform depth-first traversal of hyper tree grids, take into account more parameters (related to the grid structure) than the compact hyper tree cursor implemented in vtkHyperTree can. This is an abstract class. Cursors are created by the HyperTreeGrid implementation.

See also
vtkHyperTreeCursor vtkHyperTree vtkHyperTreeGrid
Thanks:
This class was written by Guénolé Harel and Jacques-Bernard Lekien, 2014 This class was re-written by Philippe Pebay, 2016 This work was supported by Commissariat a l'Energie Atomique (CEA/DIF)

Definition at line 45 of file vtkHyperTreeGridCursor.h.

Member Typedef Documentation

Definition at line 48 of file vtkHyperTreeGridCursor.h.

Constructor & Destructor Documentation

vtkHyperTreeGridCursor::vtkHyperTreeGridCursor ( )
protected

Constructor.

vtkHyperTreeGridCursor::~vtkHyperTreeGridCursor ( )
overrideprotected

Destructor.

Member Function Documentation

static vtkTypeBool vtkHyperTreeGridCursor::IsTypeOf ( const char *  type)
static
virtual vtkTypeBool vtkHyperTreeGridCursor::IsA ( const char *  name)
virtual

Return 1 if this class is the same type of (or a subclass of) the named class.

Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.

Reimplemented from vtkHyperTreeCursor.

static vtkHyperTreeGridCursor* vtkHyperTreeGridCursor::SafeDownCast ( vtkObjectBase o)
static
virtual vtkObjectBase* vtkHyperTreeGridCursor::NewInstanceInternal ( ) const
protectedvirtual

Reimplemented from vtkHyperTreeCursor.

vtkHyperTreeGridCursor* vtkHyperTreeGridCursor::NewInstance ( ) const
void vtkHyperTreeGridCursor::PrintSelf ( ostream &  os,
vtkIndent  indent 
)
overridevirtual

Methods invoked by print to print information about the object including superclasses.

Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.

Reimplemented from vtkHyperTreeCursor.

static vtkHyperTreeGridCursor* vtkHyperTreeGridCursor::New ( )
static
vtkHyperTreeGridCursor* vtkHyperTreeGridCursor::Clone ( )
overridevirtual

Create a copy of `this'.

Postcondition
results_exists:result!=0

Implements vtkHyperTreeCursor.

virtual void vtkHyperTreeGridCursor::Initialize ( vtkHyperTreeGrid ,
vtkIdType   
)
virtual

Initialize cursor at root of given tree index in grid.

virtual void vtkHyperTreeGridCursor::SetGrid ( vtkHyperTreeGrid )
virtual

Set the hyper tree grid to which the cursor is pointing.

virtual vtkHyperTreeGrid* vtkHyperTreeGridCursor::GetGrid ( )
virtual

Set the hyper tree grid to which the cursor is pointing.

void vtkHyperTreeGridCursor::SetTree ( vtkHyperTree )
overridevirtual

Set the hyper tree to which the cursor is pointing.

Implements vtkHyperTreeCursor.

vtkHyperTree* vtkHyperTreeGridCursor::GetTree ( )
inlineoverridevirtual

Set the hyper tree to which the cursor is pointing.

Implements vtkHyperTreeCursor.

Definition at line 76 of file vtkHyperTreeGridCursor.h.

vtkIdType vtkHyperTreeGridCursor::GetVertexId ( )
overridevirtual

Return the index of the current vertex in the tree.

Implements vtkHyperTreeCursor.

virtual vtkIdType vtkHyperTreeGridCursor::GetGlobalNodeIndex ( )
virtual

Return the global index (relative to the grid) of the current vertex in the tree.

bool vtkHyperTreeGridCursor::IsLeaf ( )
overridevirtual

Is the cursor pointing to a leaf?

Implements vtkHyperTreeCursor.

bool vtkHyperTreeGridCursor::IsRoot ( )
overridevirtual

Is the cursor at tree root?

Implements vtkHyperTreeCursor.

unsigned int vtkHyperTreeGridCursor::GetLevel ( )
inlineoverridevirtual

Get the level of the tree vertex pointed by the cursor.

Implements vtkHyperTreeCursor.

Definition at line 104 of file vtkHyperTreeGridCursor.h.

int vtkHyperTreeGridCursor::GetChildIndex ( )
overridevirtual

Return the child number of the current vertex relative to its parent.

Precondition
not_root: !IsRoot().
Postcondition
valid_range: result>=0 && result<GetNumberOfChildren()

Implements vtkHyperTreeCursor.

void vtkHyperTreeGridCursor::ToRoot ( )
overridevirtual

Move the cursor to the root vertex.

Precondition
can be root
Postcondition
is_root: IsRoot()

Implements vtkHyperTreeCursor.

void vtkHyperTreeGridCursor::ToParent ( )
overridevirtual

Move the cursor to the parent of the current vertex.

Precondition
not_root: !IsRoot()

Implements vtkHyperTreeCursor.

void vtkHyperTreeGridCursor::ToChild ( int  child)
overridevirtual

Move the cursor to child `child' of the current vertex.

Precondition
not_leaf: !IsLeaf()
valid_child: child>=0 && child<this->GetNumberOfChildren()

Implements vtkHyperTreeCursor.

void vtkHyperTreeGridCursor::ToSameVertex ( vtkHyperTreeCursor vtkNotUsedother)
inlineoverride

Move the cursor to the same vertex pointed by `other'.

Precondition
other_exists: other!=0
same_hypertree: this->SameTree(other);
Postcondition
equal: this->IsEqual(other) NB: not implemented

Definition at line 140 of file vtkHyperTreeGridCursor.h.

bool vtkHyperTreeGridCursor::IsEqual ( vtkHyperTreeCursor vtkNotUsedother)
inlineoverride

Is `this' equal to `other'?

Precondition
other_exists: other!=0
same_hypertree: this->SameTree(other); NB: not implemented

Definition at line 148 of file vtkHyperTreeGridCursor.h.

int vtkHyperTreeGridCursor::SameTree ( vtkHyperTreeCursor vtkNotUsedother)
inlineoverride

Are `this' and `other' pointing on the same hypertree?

Precondition
other_exists: other!=0 NB: not implemented

Definition at line 155 of file vtkHyperTreeGridCursor.h.

int vtkHyperTreeGridCursor::GetNumberOfChildren ( )
overridevirtual

Return the number of children for each node (non-vertex leaf) of the tree.

Postcondition
positive_number: result>0

Implements vtkHyperTreeCursor.

int vtkHyperTreeGridCursor::GetDimension ( )
overridevirtual

Return the dimension of the tree.

Postcondition
positive_result: result>0

Implements vtkHyperTreeCursor.

virtual double* vtkHyperTreeGridCursor::GetOrigin ( )
inlinevirtual

Compute the origin of the cursor.

NB: The basic hyper tree grid cursor does not have an origin.

Definition at line 173 of file vtkHyperTreeGridCursor.h.

virtual double* vtkHyperTreeGridCursor::GetSize ( )
inlinevirtual

Compute the size of the cursor.

NB: The basic hyper tree grid cursor does not have a size.

Definition at line 179 of file vtkHyperTreeGridCursor.h.

virtual void vtkHyperTreeGridCursor::GetBounds ( double  pt[6])
inlinevirtual

Compute the bounds of the cursor.

NB: The basic hyper tree grid cursor does not have bounds.

Definition at line 185 of file vtkHyperTreeGridCursor.h.

virtual void vtkHyperTreeGridCursor::GetPoint ( double  pt[3])
inlinevirtual

Compute the center coordinates of the cursor.

NB: The basic hyper tree grid cursor is always centered at 0.

Definition at line 192 of file vtkHyperTreeGridCursor.h.

virtual unsigned int vtkHyperTreeGridCursor::GetNumberOfCursors ( )
inlinevirtual

Return the number of neighborhood cursors The neighborhood definition depends on the type of cursor.

NB: Only super cursors keep track of neighborhoods.

Definition at line 199 of file vtkHyperTreeGridCursor.h.

virtual vtkHyperTreeGridCursor* vtkHyperTreeGridCursor::GetCursor ( unsigned  int)
inlinevirtual

Return the cursor pointing into i-th neighbor.

The neighborhood definition depends on the type of cursor. NB: Only super cursors keep track of neighborhoods.

Definition at line 206 of file vtkHyperTreeGridCursor.h.

virtual bool vtkHyperTreeGridCursor::GetCornerCursors ( unsigned  int,
unsigned  int,
vtkIdList  
)
inlinevirtual

Return the list of cursors pointing to the leaves touching a given corner of the cell.

Return whether the considered cell is the owner of said corner. NB: Only the Moore super cursor implements this functionality.

Definition at line 215 of file vtkHyperTreeGridCursor.h.

Member Data Documentation

vtkHyperTreeGrid* vtkHyperTreeGridCursor::Grid
protected

Definition at line 230 of file vtkHyperTreeGridCursor.h.

vtkHyperTree* vtkHyperTreeGridCursor::Tree
protected

Definition at line 233 of file vtkHyperTreeGridCursor.h.

unsigned int vtkHyperTreeGridCursor::Level
protected

Definition at line 236 of file vtkHyperTreeGridCursor.h.

vtkIdType vtkHyperTreeGridCursor::Index
protected

Definition at line 239 of file vtkHyperTreeGridCursor.h.

bool vtkHyperTreeGridCursor::Leaf
protected

Definition at line 242 of file vtkHyperTreeGridCursor.h.


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