Click or drag to resize

DataReader Class

A DataReader allows the application to declare the data it wishes to receive (i.e., make a subscription) and to access the data received by the attached Subscriber.
Inheritance Hierarchy

Namespace:  OpenDDSharp.DDS
Assembly:  OpenDDSharp (in OpenDDSharp.dll) Version: 0.5.0.0
Syntax
public class DataReader : Entity

The DataReader type exposes the following members.

Properties
  NameDescription
Public propertyInstanceHandle
Gets the InstanceHandle that represents the Entity.
(Inherited from Entity.)
Public propertyStatusChanges
Gets the list of communication statuses in the Entity that are 'triggered'. That is, the list of statuses whose value has changed since the last time the application read the status.
(Inherited from Entity.)
Public propertyStatusCondition
Allows access to the StatusCondition associated with the Entity. The returned condition can then be added to a WaitSet so that the application can wait for specific status changes that affect the Entity.
(Inherited from Entity.)
Public propertySubscriber
Gets the Subscriber to which the DataReader belongs.
Public propertyTopicDescription
Gets the ITopicDescription associated with the DataReader. This is the same ITopicDescription that was used to create the DataReader.
Top
Methods
  NameDescription
Public methodCreateQueryCondition(String, String)
Creates a QueryCondition to read samples with any sample states, any view states and any instance states.
Public methodCreateQueryCondition(SampleStateMask, ViewStateMask, InstanceStateMask, String, String)
Creates a QueryCondition with the desired sample states, view states and instance states.
Public methodCreateReadCondition
Creates a ReadCondition to read samples with any sample states, any view states and any instance states.
Public methodCreateReadCondition(SampleStateMask, ViewStateMask, InstanceStateMask)
Creates a ReadCondition to read samples with the desired sample states, view states and instance states.
Public methodDeleteContainedEntities
Deletes all the entities that were created by means of the "create" operations on the DataReader. That is, it deletes all contained ReadCondition and QueryCondition objects.
Public methodDeleteReadCondition
Deletes a ReadCondition attached to the DataReader. Since QueryCondition specializes ReadCondition it can also be used to delete a QueryCondition.
Public methodEnable
Enables the Entity. The enable operation is idempotent. Calling enable on an already enabled Entity returns Ok and has no effect.
(Inherited from Entity.)
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetListener
Allows access to the attached DataReaderListener.
Public methodGetLivelinessChangedStatus
Allows access to the LivelinessChangedStatus communication status.
Public methodGetMatchedPublicationData
This operation retrieves information on a publication that is currently "associated" with the DataReader; that is, a publication with a matching Topic and compatible QoS that the application has not indicated should be "ignored" by means of the DomainParticipant IgnorePublication operation.
Public methodGetMatchedPublications
Gets the list of publications currently "associated" with the DataReader; that is, publications that have a matching Topic and compatible QoS that the application has not indicated should be "ignored" by means of the DomainParticipant IgnorePublication operation.
Public methodGetQos
Gets the DataReader QoS policies.
Public methodGetRequestedDeadlineMissedStatus
Allows access to the RequestedDeadlineMissedStatus communication status.
Public methodGetRequestedIncompatibleQosStatus
Allows access to the RequestedIncompatibleQosStatus communication status.
Public methodGetSampleLostStatus
Allows access to the SampleLostStatus communication status.
Public methodGetSampleRejectedStatus
Allows access to the SampleRejectedStatus communication status.
Public methodGetSubscriptionMatchedStatus
Allows access to the SubscriptionMatchedStatus communication status.
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodSetListener(DataReaderListener)
Public methodSetListener(DataReaderListener, StatusMask)
Sets the DataReaderListener.
Public methodSetQos
Sets the DataReader QoS policies.
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Public methodWaitForHistoricalData
Waits until all "historical" data is received. This operation is intended only for DataReader entities that have a non-Volatile DurabilityQosPolicyKind.
Top
Remarks

A DataReader refers to exactly one ITopicDescription (either a Topic, a ContentFilteredTopic, or a MultiTopic) that identifies the data to be read. The subscription has a unique resulting type. The data-reader may give access to several instances of the resulting type, which can be distinguished from each other by their key.

All operations except for the operations SetQos(DataReaderQos), GetQos(DataReaderQos), SetListener, GetListener, Enable, and StatusCondition return the value NotEnabled if the DataReader has not been enabled yet.

See Also