Silicon
A realtime platform for creating interactive media.
Si::Node Class Reference

#include <Node.hpp>

Classes

class  ChildIterator
 

Public Member Functions

 Node ()
 Construct a new Node object. More...
 
 Node (const Node &)=delete
 
 Node (Node &&)=delete
 
 Node (std::initializer_list< Node * > children)
 Create a new Node object from a list of children. More...
 
void addChild (NotNull< Node * >)
 Add a child to this node. More...
 
void addChild (Node &)
 Add a child to this node. More...
 
NodeaddChildren (std::initializer_list< Node * > children)
 Add a list of children to this node. More...
 
ChildIterator begin () const
 Gets the begin iterator for the children of this node. More...
 
ChildIterator end () const
 Gets the end iterator for the children of this node. More...
 
virtual ~Node ()
 Destroys this node. More...
 

Protected Attributes

unsigned m_id = 0
 
NodeGraph::vertex_descriptor m_graphDescriptor
 

Static Protected Attributes

static unsigned s_currentID = 0
 
static NodeGraph s_graph
 

Detailed Description

Definition at line 47 of file Node.hpp.

Constructor & Destructor Documentation

◆ Node() [1/4]

Si::Node::Node ( )

Construct a new Node object.

Definition at line 39 of file Node.cpp.

◆ Node() [2/4]

Si::Node::Node ( const Node )
delete

◆ Node() [3/4]

Si::Node::Node ( Node &&  )
delete

◆ Node() [4/4]

Si::Node::Node ( std::initializer_list< Node * >  children)

Create a new Node object from a list of children.

Definition at line 45 of file Node.cpp.

◆ ~Node()

Si::Node::~Node ( )
virtual

Destroys this node.

Definition at line 61 of file Node.cpp.

Member Function Documentation

◆ addChild() [1/2]

void Si::Node::addChild ( Node node)

Add a child to this node.

Parameters
nodeThe child to add

Definition at line 56 of file Node.cpp.

◆ addChild() [2/2]

void Si::Node::addChild ( NotNull< Node * >  node)

Add a child to this node.

Parameters
nodeThe child to add

Definition at line 51 of file Node.cpp.

◆ addChildren()

Node & Si::Node::addChildren ( std::initializer_list< Node * >  children)

Add a list of children to this node.

Parameters
childrenThe children to add

Definition at line 77 of file Node.cpp.

◆ begin()

Node::ChildIterator Si::Node::begin ( ) const

Gets the begin iterator for the children of this node.

Returns
The begin iterator

Definition at line 67 of file Node.cpp.

◆ end()

Node::ChildIterator Si::Node::end ( ) const

Gets the end iterator for the children of this node.

Returns
The end iterator

Definition at line 72 of file Node.cpp.

Member Data Documentation

◆ m_graphDescriptor

NodeGraph::vertex_descriptor Si::Node::m_graphDescriptor
protected

Definition at line 123 of file Node.hpp.

◆ m_id

unsigned Si::Node::m_id = 0
protected

Definition at line 122 of file Node.hpp.

◆ s_currentID

unsigned Si::Node::s_currentID = 0
staticprotected

Definition at line 125 of file Node.hpp.

◆ s_graph

NodeGraph Si::Node::s_graph
staticprotected

Definition at line 126 of file Node.hpp.


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