Tree representation of the sequence.
More...
#include <SequenceTree.h>
|
| static unsigned int | CreateModule (void *ptr, DOMNode *node) |
| |
| static vector< string > | Tokenize (const string &str, const string &delimiters=",") |
| |
Tree representation of the sequence.
◆ SequenceTree()
| SequenceTree::SequenceTree |
( |
| ) |
|
◆ ~SequenceTree()
| SequenceTree::~SequenceTree |
( |
| ) |
|
public virtual default destructor
◆ AddModule()
| unsigned int SequenceTree::AddModule |
( |
string | name | ) |
|
Get a puls based on its name
- Parameters
-
| name | Unique name of the Module to be added |
◆ CreateModule()
| unsigned int SequenceTree::CreateModule |
( |
void * | ptr, |
|
|
DOMNode * | node ) |
|
static |
◆ GetAttributes()
| DOMNamedNodeMap * SequenceTree::GetAttributes |
( |
DOMNode * | node | ) |
|
Get the attributes of the given node
- Parameters
-
| node | the node for which the attributes are requested |
◆ GetChild()
| Module * SequenceTree::GetChild |
( |
DOMNode * | node, |
|
|
unsigned int | position ) |
Get child at position
@param node The node referred to.
@param position The position in the vector of children
◆ GetChildNodes()
| DOMNodeList * SequenceTree::GetChildNodes |
( |
DOMNode * | node | ) |
|
Get the child nodes of the given node
- Parameters
-
| node | the node for which the child nodes are requested |
- Returns
- pointer to DOMNodeList including the children of the node for which the children are requested
◆ GetChildren()
| vector< Module * > SequenceTree::GetChildren |
( |
DOMNode * | node | ) |
|
Get vector of chilren
@param node The node referred to.
◆ GetChildrenDynamic()
| vector< Module * > SequenceTree::GetChildrenDynamic |
( |
DOMNode * | node | ) |
|
Get vector of chilren Dynamic (old non-cached version for dynamic events such as eddy currents)
@param node The node referred to.
◆ GetContainerSequence()
◆ GetDepth()
| int SequenceTree::GetDepth |
( |
| ) |
|
|
inline |
Get the depth of the tree
- Returns
- the depth
◆ GetDOMDocument()
| DOMDocument * SequenceTree::GetDOMDocument |
( |
| ) |
|
|
inline |
Get the DOM document
- Returns
- the requested DOM document
◆ GetModule()
| Module * SequenceTree::GetModule |
( |
DOMNode * | node | ) |
|
Get a Module based on its DOMNode
- Parameters
-
◆ GetModuleByAttributeValue()
| Module * SequenceTree::GetModuleByAttributeValue |
( |
string | name, |
|
|
string | value ) |
Get first module in the tree, which has a matching attribute (name,value) pair in its DOMNode.
- Parameters
-
| name | The name of the attribute. |
| value | The value of the attribute. |
- Returns
- The module.
◆ GetModuleMap()
| map< DOMNode *, Module * > * SequenceTree::GetModuleMap |
( |
| ) |
|
|
inline |
Get the map of clonable modules
- Returns
- Map of DOM nodes and modules
◆ GetMPF()
Get the module prototype factory
- Returns
- the requested prototype factory
◆ GetParameters()
Get pointer to the sole instance of the 'Parameters' module.
◆ GetParent()
| Module * SequenceTree::GetParent |
( |
DOMNode * | node | ) |
|
Get the parent module
- Parameters
-
| node | The node referred to. |
◆ GetParentNode()
| DOMNode * SequenceTree::GetParentNode |
( |
DOMNode * | node | ) |
|
Get the Parent node of the given node
- Parameters
-
| node | the node for which the parent node is requested |
- Returns
- pointer to the requested parent node
◆ GetRootConcatSequence()
◆ GetSequenceDirectory()
| string SequenceTree::GetSequenceDirectory |
( |
| ) |
|
Get the directory of the sequence file
- Returns
- the directory
◆ GetSequenceFilename()
| string SequenceTree::GetSequenceFilename |
( |
| ) |
|
Get the filename of the sequence file
- Returns
- the filename
◆ Initialize()
| void SequenceTree::Initialize |
( |
string | seqFile | ) |
|
Initialize the sole instance
- Parameters
-
| seqFile | uri to the xml file representing the sequence tree to to Initialize from |
- Returns
- error code (0: ok, 1: file io error, 2: dtd validation error)
◆ Populate()
| unsigned int SequenceTree::Populate |
( |
bool | verbose = true | ) |
|
Populate sequence
Populate sequence with the given XML by cloning all needed objects.
◆ RunTree()
| int SequenceTree::RunTree |
( |
DOMNode * | node, |
|
|
void * | ptr, |
|
|
unsigned int(*)(void *, DOMNode *) | fun, |
|
|
int | depth = 0 ) |
Run through the sequence tree starting with a given node and perform on its children
- Parameters
-
| node | The given DOM node |
| ptr | More elaborate description here please |
| fun | Pointer to the performing function |
| depth | Depth of run (default=0). |
- Returns
- The depth of the tree
◆ SerializeModules()
| void SequenceTree::SerializeModules |
( |
string | xml_file | ) |
|
Write xml file containing all modules of the sequence framework.
◆ Tokenize()
| static vector< string > SequenceTree::Tokenize |
( |
const string & | str, |
|
|
const string & | delimiters = "," ) |
|
static |
A static string tokenizer. Needed for setting module dependencies.
- Parameters
-
| str | The string to tokenize. |
| delimiters | The delimiters to split the string. |
- Returns
- The vector of tokenized sub-strings.
◆ m_depth
| int SequenceTree::m_depth |
|
private |
◆ m_dom_doc
| DOMDocument* SequenceTree::m_dom_doc |
|
private |
The DOM document containing the whole sequence
◆ m_parameters
Pointer to the sole instance of the Parameter Module
◆ m_root_seq
◆ m_seq_file
| string SequenceTree::m_seq_file |
|
private |
◆ m_state
| bool SequenceTree::m_state |
|
private |
The documentation for this class was generated from the following files: