Loading [MathJax]/jax/input/TeX/config.js
Cantera  3.2.0a1
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
ConnectorNode Class Reference

Base class for walls and flow devices connecting reactors. More...

#include <ConnectorNode.h>

Inheritance diagram for ConnectorNode:
[legend]

Detailed Description

Base class for walls and flow devices connecting reactors.

In a reactor network, walls and flow devices (e.g., valves, pressure regulators) represent nodes in a directed bipartite graph - a graph whose vertices can be divided into two disjoint sets such that no two vertices within the same set are adjacent - with reactors forming the second set of nodes.

Since
New in Cantera 3.2.

Definition at line 27 of file ConnectorNode.h.

Public Member Functions

 ConnectorNode (const string &name="(none)")
 Transitional constructor.
 
 ConnectorNode (shared_ptr< ReactorBase > r0, shared_ptr< ReactorBase > r1, const string &name="(none)")
 Instantiate a ConnectorNode object with associated ReactorBase objects.
 
 ConnectorNode (const ConnectorNode &)=delete
 
ConnectorNodeoperator= (const ConnectorNode &)=delete
 
virtual string type () const
 String indicating the connector implemented.
 
string name () const
 Retrieve connector name.
 
void setName (const string &name)
 Set connector name.
 
void setDefaultName (map< string, int > &counts)
 Set the default name of a connector. Returns false if it was previously set.
 

Protected Attributes

pair< shared_ptr< ReactorBase >, shared_ptr< ReactorBase > > m_nodes
 Pair of reactors forming end points of the connector.
 
string m_name
 ConnectorNode name.
 
bool m_defaultNameSet = false
 true if default name has been previously set.
 

Constructor & Destructor Documentation

◆ ConnectorNode() [1/2]

ConnectorNode ( const string &  name = "(none)")
inline

Transitional constructor.

Todo:
Implement deprecation warning.

Definition at line 32 of file ConnectorNode.h.

◆ ConnectorNode() [2/2]

ConnectorNode ( shared_ptr< ReactorBase r0,
shared_ptr< ReactorBase r1,
const string &  name = "(none)" 
)
inline

Instantiate a ConnectorNode object with associated ReactorBase objects.

Parameters
r0First reactor.
r1Second reactor.
nameName of the connector.

Definition at line 38 of file ConnectorNode.h.

Member Function Documentation

◆ type()

virtual string type ( ) const
inlinevirtual

String indicating the connector implemented.

Usually corresponds to the name of the derived class.

Reimplemented in MassFlowController, PressureController, Valve, FlowDevice, WallBase, and Wall.

Definition at line 47 of file ConnectorNode.h.

◆ name()

string name ( ) const
inline

Retrieve connector name.

Definition at line 52 of file ConnectorNode.h.

◆ setName()

void setName ( const string &  name)
inline

Set connector name.

Definition at line 57 of file ConnectorNode.h.

◆ setDefaultName()

void setDefaultName ( map< string, int > &  counts)

Set the default name of a connector. Returns false if it was previously set.

Definition at line 12 of file ConnectorNode.cpp.

Member Data Documentation

◆ m_nodes

pair<shared_ptr<ReactorBase>, shared_ptr<ReactorBase> > m_nodes
protected

Pair of reactors forming end points of the connector.

Definition at line 66 of file ConnectorNode.h.

◆ m_name

string m_name
protected

ConnectorNode name.

Definition at line 68 of file ConnectorNode.h.

◆ m_defaultNameSet

bool m_defaultNameSet = false
protected

true if default name has been previously set.

Definition at line 69 of file ConnectorNode.h.


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