CCA
|
#include <Port.h>
Public Member Functions | |
virtual bool | isReady () const |
Returns, if port is configured and ready. | |
virtual void | makeOptional (bool optional) |
Declare this port optional. | |
virtual bool | isOptional () const |
Returns, if port is declared optional. | |
void | configure (const std::string &scope) |
Configure scope. | |
void | configure (PortConfigurationPtr config) |
Set port configuration. | |
virtual void | configureSpecifics ()=0 |
Porttype-specific configuration. | |
virtual PortConfigurationPtr | getConfig () const |
virtual ::rsb::ScopePtr | getScopePtr () const |
Returns scope of the port. | |
virtual bool | isLocalPort () |
virtual bool | isRemotePort () |
virtual | ~Port () |
virtual std::string | print () const =0 |
Printing information about this Port. | |
Static Public Attributes | |
static const bool | MANDATORY = false |
static const bool | OPTIONAL = true |
Protected Member Functions | |
Port (bool optional=false) | |
Protected constructor. | |
Protected Attributes | |
PortConfigurationPtr | config |
RSB Participant config for this port. | |
bool | configured |
bool | optional |
Detailed Description
Constructor & Destructor Documentation
cca::Port::~Port | ( | ) | [virtual] |
cca::Port::Port | ( | bool | optional = false | ) | [protected] |
Member Function Documentation
void cca::Port::configure | ( | const std::string & | scope | ) |
Configure scope.
- Parameters:
-
scope Scope
Definition at line 60 of file Port.cpp.
References cca::PortConfiguration::DEFAULT().
Referenced by cca::Component::configureBeatInputPort(), cca::timing::BeatProvider::configureBeatOutputPort(), cca::Component::configureStateInputPort(), cca::Component::configureStateOutputPort(), and cca::timing::HeartBeat::HeartBeat().
void cca::Port::configure | ( | PortConfigurationPtr | config | ) |
Set port configuration.
- Parameters:
-
config Port configuration
Definition at line 64 of file Port.cpp.
References config, configured, and configureSpecifics().
virtual void cca::Port::configureSpecifics | ( | ) | [pure virtual] |
Porttype-specific configuration.
Needs to be implemented by child classes. Port configuration is already constructed at this point, but port is not yet considered configured.
Implemented in cca::InputPort< DATATYPE >, cca::InputPort< ComponentState >, cca::InputPort< cca::timing::Tick >, cca::InputPort< DTOTYPE >, cca::OutputPort< DATATYPE >, cca::OutputPort< ComponentState >, cca::OutputPort< DTOTYPE >, cca::OutputPort< Tick >, and cca::InputPortBase.
Referenced by configure().
PortConfigurationPtr cca::Port::getConfig | ( | ) | const [virtual] |
- Returns:
Definition at line 86 of file Port.cpp.
References config.
Referenced by cca::OutputPort< Tick >::print(), and cca::InputPort< DTOTYPE >::print().
ScopePtr cca::Port::getScopePtr | ( | ) | const |
Returns scope of the port.
- Returns:
Definition at line 90 of file Port.cpp.
References config.
Referenced by cca::OutputPort< Tick >::print(), and cca::InputPort< DTOTYPE >::print().
bool cca::Port::isLocalPort | ( | ) | [virtual] |
- Returns:
- If this port is configured to communicate via local transport.
Definition at line 72 of file Port.cpp.
References config, and configured.
bool cca::Port::isOptional | ( | ) | const [virtual] |
bool cca::Port::isReady | ( | ) | const [virtual] |
Returns, if port is configured and ready.
- Returns:
- Port is configured and ready.
Definition at line 48 of file Port.cpp.
References configured.
Referenced by cca::Component::publishState().
bool cca::Port::isRemotePort | ( | ) | [virtual] |
- Returns:
- If this port is configured to communicate via remote transport.
Definition at line 79 of file Port.cpp.
References config, and configured.
void cca::Port::makeOptional | ( | bool | optional | ) | [virtual] |
virtual std::string cca::Port::print | ( | ) | const [pure virtual] |
Printing information about this Port.
Implemented in cca::InputPort< DATATYPE >, cca::InputPort< ComponentState >, cca::InputPort< cca::timing::Tick >, cca::InputPort< DTOTYPE >, cca::OutputPort< DATATYPE >, cca::OutputPort< ComponentState >, cca::OutputPort< DTOTYPE >, and cca::OutputPort< Tick >.
Member Data Documentation
PortConfigurationPtr cca::Port::config [protected] |
RSB Participant config for this port.
Definition at line 137 of file Port.h.
Referenced by configure(), cca::InputPortBase::configureSpecifics(), cca::OutputPort< Tick >::configureSpecifics(), cca::InputPort< DTOTYPE >::configureSpecifics(), getConfig(), getScopePtr(), isLocalPort(), and isRemotePort().
bool cca::Port::configured [protected] |
Definition at line 139 of file Port.h.
Referenced by cca::InputPort< DTOTYPE >::add(), cca::InputPort< DTOTYPE >::addEvent(), configure(), cca::InputPort< DTOTYPE >::empty(), cca::InputPort< DTOTYPE >::get(), isLocalPort(), isReady(), isRemotePort(), cca::InputPort< DTOTYPE >::newItem(), cca::OutputPort< Tick >::print(), cca::InputPort< DTOTYPE >::print(), cca::OutputPort< Tick >::publish(), cca::InputPort< DTOTYPE >::purge(), and cca::InputPort< DTOTYPE >::size().
const bool cca::Port::MANDATORY = false [static] |
const bool cca::Port::OPTIONAL = true [static] |
bool cca::Port::optional [protected] |
Definition at line 139 of file Port.h.
Referenced by isOptional(), makeOptional(), cca::OutputPort< Tick >::print(), and cca::InputPort< DTOTYPE >::print().
The documentation for this class was generated from the following files: