Click or drag to resize

SubscriberGetDataReaders Method (IListDataReader)

Allows the application to access the DataReader objects that contain samples with any sample states, any view states, and any instance states.

Namespace:  OpenDDSharp.DDS
Assembly:  OpenDDSharp (in OpenDDSharp.dll) Version: 0.5.0.0
Syntax
public ReturnCode GetDataReaders(
	IList<DataReader> readers
)

Parameters

readers
Type: System.Collections.GenericIListDataReader
The DataReader collection to be filled up.

Return Value

Type: ReturnCode
The ReturnCode that indicates the operation result.
Remarks

If the PresentationQosPolicy of the Subscriber to which the DataReader belongs has the AccessScope set to GroupPresentationQos, this operation should only be invoked inside a BeginAccess/EndAccess block. Otherwise it will return the error PreconditionNotMet.

Depending on the setting of the PresentationQosPolicy, the returned collection of DataReader objects may be a 'set' containing each DataReader at most once in no specified order, or a 'list' containing each DataReader one or more times in a specific order.

  1. If AccessScope is InstancePresentationQos or TopicPresentationQos the returned collection behaves as a 'set'.
  2. If AccessScope is GroupPresentationQos and OrderedAccess is set to , then the returned collection behaves as a 'list'.

This difference is due to the fact that, in the second situation it is required to access samples belonging to different DataReader objects in a particular order. In this case, the application should process each DataReader in the same order it appears in the 'list' and Read or Take exactly one sample from each DataReader.

See Also