#include </home/sspr/src/www/orocos-1.0/export/build/orocos-rtt-1.2.2/build/rtt/DataPort.hpp>
Inheritance diagram for ReadDataPort:

Use connection() to access the data object. If the port is not connected, connection() returns null.
| T | The type of the data of the data object. |
Public Types | |
| enum | PortType { ReadPort, WritePort, ReadWritePort } |
| This enum classifies if a port is inbound outbound or both. | |
Public Member Functions | |
| ReadDataPort (const std::string &name) | |
| Construct an unconnected Port to a readable data object. | |
| ReadDataPort & | operator= (DataObjectInterface< T > *impl) |
| Provide a new implementation for the connection of this port. | |
| T | Get () const |
| Get the current value of this Port. | |
| void | Get (T &result) const |
| Get the current value of this Port. | |
| virtual PortType | getPortType () const |
| Get the PortType of this port. | |
| bool | connect (typename DataConnectionInterface< T >::shared_ptr conn) |
| Connect a readable data object connection to this Port. | |
| virtual ConnectionInterface::shared_ptr | connection () const |
| Returns the connection in which this Port currently participates. | |
| bool | connected () const |
| Inspect if this Port is currently connected with another Port. | |
| bool | connectTo (ConnectionInterface::shared_ptr other) |
| Connect this port to a Connection. | |
| void | disconnect () |
| No longer participate in a connection. | |
| const DataObjectInterface< T > * | data () const |
| Get the data object to read from. | |
| virtual PortInterface * | clone () const |
| Create a clone of this port with the same name. | |
| virtual PortInterface * | antiClone () const |
| Create the anti-clone (inverse port) of this port with the same name A port for reading will return a new port for writing and vice versa. | |
| virtual TaskObject * | createPortObject () |
| Create accessor Object for this Port, for addition to a TaskContext Object interface. | |
| const std::string & | getName () const |
| Get the name of this Port. | |
| bool | setName (const std::string &name) |
| Change the name of this unconnected Port. | |
| bool | ready () const |
| Returns true if this Port is ready to be used. | |
| virtual bool | connectTo (PortInterface *other) |
| Connect to another Port and create a new connection if necessary. | |
| virtual ConnectionInterface::shared_ptr | createConnection (PortInterface *other, ConnectionTypes::ConnectionType con_type=ConnectionTypes::lockfree) |
| Create a connection object from this port to another port. | |
| virtual ConnectionInterface::shared_ptr | createConnection (ConnectionTypes::ConnectionType con_type=ConnectionTypes::lockfree) |
| Create a new connection object to which this port is subscribed. | |
Protected Attributes | |
|
DataConnectionInterface< T >::shared_ptr | mconn |
| The connection to read from. | |
| std::string | portname |
| ReadDataPort | ( | const std::string & | name | ) | [inline] |
Construct an unconnected Port to a readable data object.
| name | The name of this port. |
| ReadDataPort< T > & operator= | ( | DataObjectInterface< T > * | impl | ) |
Provide a new implementation for the connection of this port.
If this port is not connected, a new connection is created.
Reimplemented in DataPort.
| T Get | ( | ) | const [inline] |
Get the current value of this Port.
| this->data()->Get() | if this->connected() | |
| T() | if !this->connected() |
Reimplemented in DataPort.
| void Get | ( | T & | result | ) | const [inline] |
Get the current value of this Port.
| result | the variable in which the port value will be stored. |
result is unmodified if !this->connected()
Reimplemented in DataPort.
| virtual ConnectionInterface::shared_ptr connection | ( | ) | const [inline, virtual] |
Returns the connection in which this Port currently participates.
It is possible that this port is part of a dormant connection, ( the connection object is not in the connected() state), in that case this method will return null, until the dormant connection becomes connected().
| null | if not connected to another Port. |
Implements PortInterface.
Reimplemented in DataPort.
| bool connectTo | ( | ConnectionInterface::shared_ptr | other | ) | [inline, virtual] |
Connect this port to a Connection.
If the connection is in the connected() state, this port will participate in that connection, otherwise, the port will become connected once conn becomes connected().
Implements PortInterface.
Reimplemented in DataPort.
| const DataObjectInterface<T>* data | ( | ) | const [inline] |
Get the data object to read from.
The Task may use this to read from a Data object connection connected to this port.
Reimplemented in DataPort.
| bool setName | ( | const std::string & | name | ) | [inherited] |
Change the name of this unconnected Port.
One can only change the name when it is not yet connected.
| true | if !this->connected(), the name has changed. | |
| false | if this->connected(), the name has not been changed. |
| bool ready | ( | ) | const [inherited] |
Returns true if this Port is ready to be used.
Identical to connected().
| virtual bool connectTo | ( | PortInterface * | other | ) | [virtual, inherited] |
Connect to another Port and create a new connection if necessary.
1.5.1