SyDEVS
v0.6.7
Multiscale Simulation and Systems Modeling Library
|
A class template for flow input ports. More...
#include <port.h>
Inherits sydevs::systems::port_base< flow, input, T >.
Public Member Functions | |
port (const std::string &port_name, const node_interface &external_interface) | |
Constructs a port<flow, input> object. More... | |
port (port &&)=default | |
Move constructor. More... | |
port & | operator= (port &&)=default |
Move assignment. More... | |
~port ()=default | |
Destructor. More... | |
const T & | value () const |
Returns the current value attached to the port. More... | |
void | print_on_use (bool flag=true) const |
If flag is true , all values communicated through this port are printed. More... | |
Public Member Functions inherited from sydevs::systems::port_base< flow, input, T > | |
port_base (const port_base &)=delete | |
No copy constructor. More... | |
port_base (port_base &&)=default | |
Move constructor. More... | |
port_base & | operator= (const port_base &)=delete |
No copy assignment. More... | |
port_base & | operator= (port_base &&)=default |
Move assignment. More... | |
virtual | ~port_base ()=default |
Destructor. More... | |
const std::string & | port_name () const |
Returns the name of the port. More... | |
int64 | port_index () const |
Returns the index of the port within the encompassing node_interface object. More... | |
int64 | node_index () const |
Returns the index of the node within the encompassing node_structure object. More... | |
const node_interface & | external_interface () const |
Returns the encomassing node_interface object. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from sydevs::systems::port_base< flow, input, T > | |
port_base (const std::string &port_name, int64 port_index, node_interface &external_interface) | |
A class template for flow input ports.
A port<flow, input>
object is used to supply a system_node
object with a parameter at the beginning of a simulation.
T | The type of data handled by the port. |
sydevs::systems::port< flow, input, T >::port | ( | const std::string & | port_name, |
const node_interface & | external_interface | ||
) |
Constructs a port<flow, input>
object.
The port is created and registered with the encompassing node_interface
object.
port_name | The name of the port. |
external_interface | The encompassing node_interface object associated with the node. |
T | The type of data handled by the port. |
|
default |
Move constructor.
|
default |
Destructor.
|
default |
Move assignment.
void sydevs::systems::port< flow, input, T >::print_on_use | ( | bool | flag = true | ) | const |
If flag
is true
, all values communicated through this port are printed.
const T & sydevs::systems::port< flow, input, T >::value | ( | ) | const |
Returns the current value attached to the port.