COPASI API  4.40.278
CDependencyGraph Class Reference

#include <CDependencyGraph.h>

Public Member Functions

void addDependent (const size_t &node, const size_t &dependent)
 
 CDependencyGraph ()
 
void clear ()
 
const std::set< size_t > & getDependents (const size_t &node) const
 
void resize (const size_t &n)
 
 ~CDependencyGraph ()
 

Private Member Functions

void addNode (const size_t &node)
 

Private Attributes

std::vector< CDependencyGraphNodemNodes
 

Friends

std::ostream & operator<< (std::ostream &os, const CDependencyGraph &d)
 

Detailed Description

CDependencyGraph describes a dependency graph.

Constructor & Destructor Documentation

◆ CDependencyGraph()

CDependencyGraph::CDependencyGraph ( )

Constructor

◆ ~CDependencyGraph()

CDependencyGraph::~CDependencyGraph ( )

Desctructor

Member Function Documentation

◆ addDependent()

void CDependencyGraph::addDependent ( const size_t &  node,
const size_t &  dependent 
)

Add a dependent for a particular node.

Parameters
nodeThe number of the node.
dependentThe number of the dependent node.

References mNodes.

Referenced by CHybridMethod::setupDependencyGraph(), and CStochMethod::setupDependencyGraph().

◆ addNode()

void CDependencyGraph::addNode ( const size_t &  node)
private

Add a node with a given number.

Parameters
nodeThe number of the node to add.

References mNodes.

◆ clear()

void CDependencyGraph::clear ( )

◆ getDependents()

const std::set< size_t > & CDependencyGraph::getDependents ( const size_t &  node) const

Retrieve a vector of dependents for a given node.

Parameters
nodeThe number of the node to access.
Returns
A vector of node numbers.

References mNodes.

Referenced by CStochNextReactionMethod::updatePriorityQueue().

◆ resize()

void CDependencyGraph::resize ( const size_t &  n)

Friends And Related Function Documentation

◆ operator<<

std::ostream& operator<< ( std::ostream &  os,
const CDependencyGraph d 
)
friend

insert operator

Member Data Documentation

◆ mNodes

std::vector<CDependencyGraphNode> CDependencyGraph::mNodes
private

A vector containing the nodes in the graph

Referenced by addDependent(), addNode(), clear(), getDependents(), and resize().


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