Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

ddsnc::DDSSubscriber Class Reference

#include <DDSSubscriber.h>

Inheritance diagram for ddsnc::DDSSubscriber:

Inheritance graph
[legend]
Collaboration diagram for ddsnc::DDSSubscriber:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 DDSSubscriber (const char *channelName)
 ~DDSSubscriber ()
void consumerReady ()
template<class DRV, class DR, class D> void addSubscription (void(*templateFunction)(D, void *), void *handlerParam=0)
template<class D, class TSV, class TSI> void initialize ()

Public Attributes

DDS::DataReaderQos drQos

Protected Attributes

DDS::SubscriberQos subQos

Private Member Functions

int attachToTransport ()
int createSubscriber ()

Private Attributes

DDS::Subscriber_var sub
OpenDDS::DCPS::SubscriberImpl * sub_impl
DDS::DataReaderListener_var * listener

Detailed Description

The Subscriber implementation of ACS Notification Channel based on DDS

See also:
DDSHelper
Author:
Jorge Avarias <javarias[at]inf.utfsm.cl>


Constructor & Destructor Documentation

ddsnc::DDSSubscriber::DDSSubscriber const char *  channelName  )  [inline]
 

Constructor of the class.

See also:
DDSHelper

ddsnc::DDSSubscriber::~DDSSubscriber  )  [inline]
 


Member Function Documentation

template<class DRV, class DR, class D>
void ddsnc::DDSSubscriber::addSubscription void(*  templateFunction)(D, void *),
void *  handlerParam = 0
[inline]
 

The method maintains the name provided by the old acsnc API. Actually this function initializes the DataReader listener.

The <type> corresponds to the name of data type (without namespace) defined in the idl file, the classes required by the template are autogenerated by dcps_ts.pl tools and are specific to the data type defined.

D <type> struct DR <type>DataReader class DRV <type>DataReader_var class

Parameters:
(*templateFunction)(D,void *) callback function to handle data received by DataReaderListener
*handlerParam 

int ddsnc::DDSSubscriber::attachToTransport  )  [private]
 

void ddsnc::DDSSubscriber::consumerReady  ) 
 

Initialize the DataReader with Qos. This method leaves the Subscriber initializated when is executed.

See also:
drQos

int ddsnc::DDSSubscriber::createSubscriber  )  [private]
 

Creates the subscriber with default QoS or QoS with a partition

See also:
initialize();

template<class D, class TSV, class TSI>
void ddsnc::DDSSubscriber::initialize void   )  [inline]
 

Create the participant, initialize the subscriber with the partition provided in the channelName constructor parameter, if there is not partition, initialize the subscriber with default QoS properties, then initialize the transport for the participant, create the subscriber and initialize the topic with topicNanme provided as parameter of the constructor and with data type support defined by templates and finally initialize the data reader QoS with default values

The <type> corresponds to the name of data type (without namespace) defined in the idl file, the classes required by the template are autogenerated by dcps_ts.pl tools and are specific to the data type defined.

D <type> struct TSV <type>TypeSupport_var class TSI <type>TypeSupportImpl class


Member Data Documentation

DDS::DataReaderQos ddsnc::DDSSubscriber::drQos
 

Data Writer Qos, can be modified according OpenDDS API, the Qos properties will be applied when is called consumerReady for first time and they cannot be changed after that.

See also:
consumerReady()

initialize()

DDS::DataReaderListener_var* ddsnc::DDSSubscriber::listener [private]
 

DDS::Subscriber_var ddsnc::DDSSubscriber::sub [private]
 

OpenDDS::DCPS::SubscriberImpl* ddsnc::DDSSubscriber::sub_impl [private]
 

DDS::SubscriberQos ddsnc::DDSSubscriber::subQos [protected]
 


The documentation for this class was generated from the following file:
Generated on Thu Apr 30 02:37:25 2009 for ACS C++ API by doxygen 1.3.8