RTI Connext Java API  Version 5.1.0
WriteParams_t Class Reference

<<eXtension>> Input parameters for writing with com.rti.ndds.example.FooDataWriter.write_w_params, com.rti.ndds.example.FooDataWriter.dispose_w_params, com.rti.ndds.example.FooDataWriter.register_instance_w_params, com.rti.ndds.example.FooDataWriter.unregister_instance_w_params More...

Inheritance diagram for WriteParams_t:
Copyable PublicationPriority

Public Member Functions

 WriteParams_t ()
 Construct a new WriteParams_t.
 
 WriteParams_t (boolean replace_auto, SampleIdentity_t identity, SampleIdentity_t related_sample_identity, Time_t source_timestamp, Cookie_t cookie, InstanceHandle_t handle, int priority)
 Construct a new WriteParams_t with the given members.
 
- Public Member Functions inherited from Struct
abstract boolean equals (Object obj)
 
abstract int hashCode ()
 
String toString ()
 
- Public Member Functions inherited from Copyable
Object copy_from (Object src)
 Copy value of a data type from source.
 

Public Attributes

SampleIdentity_t identity
 Identity of the sample.
 
final SampleIdentity_t related_sample_identity
 The identity of another sample related to this one.
 
Time_t source_timestamp = new Time_t(Time_t.TIME_INVALID)
 Source timestamp upon write.
 
InstanceHandle_t handle = new InstanceHandle_t()
 Instance handle.
 
int priority = UNDEFINED
 Publication priority.
 

Additional Inherited Members

- Static Public Attributes inherited from PublicationPriority
static final int UNDEFINED = 0
 
static final int AUTOMATIC = -1
 
- Protected Member Functions inherited from Struct
 Struct ()
 
abstract void pull_from_nativeI (long native_status)
 
abstract void push_to_nativeI (long native_status)
 

Detailed Description

Constructor & Destructor Documentation

Construct a new WriteParams_t.

WriteParams_t ( boolean  replace_auto,
SampleIdentity_t  identity,
SampleIdentity_t  related_sample_identity,
Time_t  source_timestamp,
Cookie_t  cookie,
InstanceHandle_t  handle,
int  priority 
)

Construct a new WriteParams_t with the given members.

Member Data Documentation

SampleIdentity_t identity
Initial value:
=
new SampleIdentity_t(SampleIdentity_t.AUTO_SAMPLE_IDENTITY)

Identity of the sample.

Identifies the sample being written. The identity consists of a pair (Virtual Writer GUID, Virtual Sequence Number).

Use the default value to let RTI Connext determine the sample identity as follows:

  • The sequence number is increased by one with respect to the previous value.

The virtual sequence numbers for a virtual writer must be strictly monotonically increasing. If the user tries to write a sample with a sequence number smaller or equal to the last sequence number, the write operation will fail.

A DataReader can access the identity of a received sample by using the fields com.rti.dds.subscription.SampleInfo.original_publication_virtual_guid and com.rti.dds.subscription.SampleInfo.original_publication_virtual_sequence_number in the com.rti.dds.subscription.SampleInfo.

[default] com.rti.dds.infrastructure.SampleIdentity_t.SampleIdentity_t.AUTO_SAMPLE_IDENTITY.

final SampleIdentity_t related_sample_identity
Initial value:
=
new SampleIdentity_t(SampleIdentity_t.UNKNOWN_SAMPLE_IDENTITY)

The identity of another sample related to this one.

Identifies another sample that is logically related to the one that is written.

When this field is set, the related sample identity is propagated an subscribing applications can retrieve it from the com.rti.dds.subscription.SampleInfo (see com.rti.dds.subscription.SampleInfo.get_related_sample_identity).

The default value is com.rti.dds.infrastructure.SampleIdentity_t.SampleIdentity_t.UNKNOWN_SAMPLE_IDENTITY, and is not propagated.

A DataReader can access the related identity of a received sample by using the fields com.rti.dds.subscription.SampleInfo.related_original_publication_virtual_guid and com.rti.dds.subscription.SampleInfo.related_original_publication_virtual_sequence_number in the com.rti.dds.subscription.SampleInfo.

[default] com.rti.dds.infrastructure.SampleIdentity_t.SampleIdentity_t.UNKNOWN_SAMPLE_IDENTITY

Time_t source_timestamp = new Time_t(Time_t.TIME_INVALID)

Source timestamp upon write.

Specifies the source timestamp that will be available to the com.rti.dds.subscription.DataReader objects by means of the source_timestamp attribute within the com.rti.dds.subscription.SampleInfo.

[default] com.rti.dds.infrastructure.Time_t.INVALID.

Instance handle.

Either the handle returned by a previous call to com.rti.ndds.example.FooDataWriter.register_instance, or else the special value com.rti.dds.infrastructure.InstanceHandle_t.InstanceHandle_t.HANDLE_NIL.

[default] com.rti.dds.infrastructure.InstanceHandle_t.InstanceHandle_t.HANDLE_NIL

int priority = UNDEFINED

Publication priority.

A positive integer value designating the relative priority of the com.rti.dds.publication.DataWriter, used to determine the transmission order of pending writes.

Use of publication priorities requires the asynchronous publisher (com.rti.dds.infrastructure.PublishModeQosPolicyKind.PublishModeQosPolicyKind.ASYNCHRONOUS_PUBLISH_MODE_QOS) with com.rti.dds.publication.FlowControllerProperty_t.scheduling_policy set to com.rti.dds.publication.FlowControllerSchedulingPolicy.FlowControllerSchedulingPolicy.HPF_FLOW_CONTROLLER_SCHED_POLICY.

Larger numbers have higher priority.

For multi-channel DataWriters, if the publication priority of any channel is set to any value other than com.rti.dds.infrastructure.PUBLICATION_PRIORITY_UNDEFINED, then the channel's priority will take precedence over that of the DataWriter.

For multi-channel DataWriters, if the publication priority of any channel is com.rti.dds.infrastructure.PUBLICATION_PRIORITY_UNDEFINED, then the channel will inherit the publication priority of the DataWriter.

If the publicaton priority of the DataWriter, and of any channel of a multi-channel DataWriter, are com.rti.dds.infrastructure.PUBLICATION_PRIORITY_UNDEFINED, then the priority of the DataWriter or DataWriter channel will be assigned the lowest priority value.

If the publication priority of the DataWriter is com.rti.dds.infrastructure.PUBLICATION_PRIORITY_AUTOMATIC, then the DataWriter will be assigned the priority of the largest publication priority of all samples in the DataWriter.

The publication priority of each sample can be set in the com.rti.dds.infrastructure.WriteParams_t of the com.rti.ndds.example.FooDataWriter.write_w_params function.

For dispose and unregister samples, use the com.rti.dds.infrastructure.WriteParams_t of com.rti.ndds.example.FooDataWriter.dispose_w_params and com.rti.ndds.example.FooDataWriter.unregister_instance_w_params.

[default] com.rti.dds.infrastructure.PUBLICATION_PRIORITY_UNDEFINED


RTI Connext Java API Version 5.1.0 Copyright © Mon Feb 3 2014 Real-Time Innovations, Inc