#include <SymbolNode.h>
Public Member Functions | |
SymbolNode () | |
Private Types | |
enum | SymbolNodeType { NODE = 0 , LEAF = 1 } |
Initializer Methods | |
Methods related to instantiation and destruction. | |
std::map< std::string, te::qt::widgets::SymbolNode * > | m_nodes |
te::qt::widgets::SymbolNode * | m_parent |
SymbolNodeType | m_type |
std::map< std::string, Symbol * > | m_symbolMap |
The set of symbol. More... | |
std::string | m_id |
std::string | m_name |
SymbolNode (const std::string &name, te::qt::widgets::SymbolNode *parent=nullptr) | |
Default constructor. More... | |
virtual | ~SymbolNode () |
Destructor. More... | |
virtual void | add (te::qt::widgets::SymbolNode *node) |
virtual te::qt::widgets::SymbolNode * | remove (te::qt::widgets::SymbolNode *node) |
virtual void | erase (te::qt::widgets::SymbolNode *node) |
virtual void | eraseAll () |
const std::map< std::string, te::qt::widgets::SymbolNode * > & | getNodes () const |
std::size_t | getNodesCount () const |
void | addSymbol (Symbol *symbol) |
It inserts a new symbol to this library. More... | |
Symbol * | removeSymbol (Symbol *symbol) |
It removes the symbol from this library. More... | |
void | eraseSymbol (Symbol *symbol) |
It removes the symbol from this library. More... | |
const std::map< std::string, te::qt::widgets::Symbol * > & | getSymbols () const |
te::qt::widgets::Symbol * | findSymbolById (const std::string &id) const |
It returns the symbol identified by a given id or NULL if none is found. More... | |
te::qt::widgets::SymbolNode * | findParentBySymbolId (const std::string &id) |
It returns the symbol identified by a given id or NULL if none is found. More... | |
te::qt::widgets::SymbolNode * | findNodeById (const std::string &id) const |
It returns the group identified by a given id or NULL if none is found. More... | |
te::qt::widgets::SymbolNode * | findNodeFromTopLevelByName (const std::string &name) const |
It returns the group identified by a given id or NULL if none is found. More... | |
te::qt::widgets::SymbolNode * | findNodeFromTopLevelById (const std::string &id) const |
It returns the group identified by a given id or NULL if none is found. More... | |
bool | hasNodes () const |
bool | hasSymbols () const |
std::string | getID () const |
void | setName (const std::string &name) |
std::string | getName () const |
void | setParent (SymbolNode *parent) |
SymbolNode * | getParent () const |
SymbolNodeType | getType () |
void | clear () |
It removes all symbols from this library. More... | |
Definition at line 48 of file SymbolNode.h.
|
private |
Enumerator | |
---|---|
NODE | node |
LEAF | leaf |
Definition at line 57 of file SymbolNode.h.
te::qt::widgets::SymbolNode::SymbolNode | ( | ) |
te::qt::widgets::SymbolNode::SymbolNode | ( | const std::string & | name, |
te::qt::widgets::SymbolNode * | parent = nullptr |
||
) |
Default constructor.
|
virtual |
Destructor.
|
virtual |
void te::qt::widgets::SymbolNode::addSymbol | ( | Symbol * | symbol | ) |
It inserts a new symbol to this library.
symbol | The new symbol that will be added to this library. |
|
protected |
It removes all symbols from this library.
|
virtual |
|
virtual |
void te::qt::widgets::SymbolNode::eraseSymbol | ( | Symbol * | symbol | ) |
It removes the symbol from this library.
symbol | The symbol to be removed. |
Exception | If the symbol doesn't exist it will raise an exception. |
te::qt::widgets::SymbolNode * te::qt::widgets::SymbolNode::findNodeById | ( | const std::string & | id | ) | const |
It returns the group identified by a given id or NULL if none is found.
name | The id of the symbol we are looking for. |
te::qt::widgets::SymbolNode * te::qt::widgets::SymbolNode::findNodeFromTopLevelById | ( | const std::string & | id | ) | const |
It returns the group identified by a given id or NULL if none is found.
name | The name of the group we are looking for. |
te::qt::widgets::SymbolNode * te::qt::widgets::SymbolNode::findNodeFromTopLevelByName | ( | const std::string & | name | ) | const |
It returns the group identified by a given id or NULL if none is found.
name | The name of the group we are looking for. |
te::qt::widgets::SymbolNode * te::qt::widgets::SymbolNode::findParentBySymbolId | ( | const std::string & | id | ) |
It returns the symbol identified by a given id or NULL if none is found.
name | The id of the symbol we are looking for. |
te::qt::widgets::Symbol * te::qt::widgets::SymbolNode::findSymbolById | ( | const std::string & | id | ) | const |
It returns the symbol identified by a given id or NULL if none is found.
name | The id of the symbol we are looking for. |
std::string te::qt::widgets::SymbolNode::getID | ( | ) | const |
std::string te::qt::widgets::SymbolNode::getName | ( | ) | const |
const std::map< std::string, te::qt::widgets::SymbolNode * > & te::qt::widgets::SymbolNode::getNodes | ( | ) | const |
std::size_t te::qt::widgets::SymbolNode::getNodesCount | ( | ) | const |
SymbolNode * te::qt::widgets::SymbolNode::getParent | ( | ) | const |
const std::map< std::string, te::qt::widgets::Symbol * > & te::qt::widgets::SymbolNode::getSymbols | ( | ) | const |
|
protected |
bool te::qt::widgets::SymbolNode::hasNodes | ( | ) | const |
bool te::qt::widgets::SymbolNode::hasSymbols | ( | ) | const |
|
virtual |
It removes the symbol from this library.
symbol | The symbol to be removed. |
Exception | If the symbol doesn't exist it will raise an exception. |
void te::qt::widgets::SymbolNode::setName | ( | const std::string & | name | ) |
void te::qt::widgets::SymbolNode::setParent | ( | SymbolNode * | parent | ) |
|
protected |
Definition at line 208 of file SymbolNode.h.
|
protected |
Definition at line 209 of file SymbolNode.h.
|
protected |
Definition at line 204 of file SymbolNode.h.
|
protected |
Definition at line 205 of file SymbolNode.h.
|
protected |
The set of symbol.
Definition at line 207 of file SymbolNode.h.
|
protected |
Definition at line 206 of file SymbolNode.h.