Fast DDS  Version 3.1.2
Fast DDS
Loading...
Searching...
No Matches
LivelinessQosPolicy Class Reference

Determines the mechanism and parameters used by the application to determine whether an Entity is “active” (alive). More...

#include <QosPolicies.hpp>

Inheritance diagram for LivelinessQosPolicy:

Public Member Functions

FASTDDS_EXPORTED_API LivelinessQosPolicy ()
 Constructor.
 
virtual FASTDDS_EXPORTED_API ~LivelinessQosPolicy ()=default
 Destructor.
 
bool operator== (const LivelinessQosPolicy &b) const
 
void clear () override
 Clears the QosPolicy object.
 
- Public Member Functions inherited from Parameter_t
FASTDDS_EXPORTED_API Parameter_t ()
 Constructor without parameters.
 
FASTDDS_EXPORTED_API Parameter_t (ParameterId_t pid, uint16_t length)
 Constructor using a parameter PID and the parameter length.
 
virtual FASTDDS_EXPORTED_API ~Parameter_t ()
 Destructor.
 
bool operator== (const Parameter_t &b) const
 
- Public Member Functions inherited from QosPolicy
 QosPolicy ()
 Constructor without parameters.
 
 QosPolicy (bool send_always)
 Constructor.
 
 QosPolicy (const QosPolicy &b)=default
 Copy Constructor.
 
virtual ~QosPolicy ()=default
 Destructor.
 
bool operator== (const QosPolicy &b) const
 
QosPolicyoperator= (const QosPolicy &b)=default
 
virtual bool send_always () const
 Whether it should always be sent.
 

Public Attributes

LivelinessQosPolicyKind kind
 Liveliness kind
By default, AUTOMATIC_LIVELINESS.
 
fastdds::dds::Duration_t lease_duration
 Period within which liveliness should be asserted.
 
fastdds::dds::Duration_t announcement_period
 The period for automatic assertion of liveliness.
 
- Public Attributes inherited from Parameter_t
ParameterId_t Pid
 Parameter ID.
By default, PID_PAD.
 
uint16_t length
 Parameter length.
By default, 0.
 
- Public Attributes inherited from QosPolicy
bool hasChanged
 Boolean that indicates if the Qos has been changed with respect to the default Qos.
 

Additional Inherited Members

- Protected Attributes inherited from QosPolicy
bool send_always_
 Boolean that indicates if the Qos has to be sent even if it is not changed.
 

Detailed Description

Determines the mechanism and parameters used by the application to determine whether an Entity is “active” (alive).

The “liveliness” status of an Entity is used to maintain instance ownership in combination with the setting of the OwnershipQosPolicy. The application is also informed via listener when an Entity is no longer alive.

The DataReader requests that liveliness of the writers is maintained by the requested means and loss of liveliness is detected with delay not to exceed the lease_duration.

The DataWriter commits to signaling its liveliness using the stated means at intervals not to exceed the lease_duration. Listeners are used to notify the DataReaderof loss of liveliness and DataWriter of violations to the liveliness contract.

Constructor & Destructor Documentation

◆ LivelinessQosPolicy()

FASTDDS_EXPORTED_API LivelinessQosPolicy ( )
inline

Constructor.

◆ ~LivelinessQosPolicy()

virtual FASTDDS_EXPORTED_API ~LivelinessQosPolicy ( )
virtualdefault

Destructor.

Member Function Documentation

◆ clear()

void clear ( )
inlineoverridevirtual

Clears the QosPolicy object.

Implements QosPolicy.

◆ operator==()

bool operator== ( const LivelinessQosPolicy b) const
inline

Member Data Documentation

◆ announcement_period

fastdds::dds::Duration_t announcement_period

The period for automatic assertion of liveliness.

Only used for DataWriters with AUTOMATIC liveliness. By default, dds::c_TimeInfinite.

Warning
When not infinite, must be < lease_duration, and it is advisable to be less than 0.7*lease_duration.

◆ kind

Liveliness kind
By default, AUTOMATIC_LIVELINESS.

◆ lease_duration

fastdds::dds::Duration_t lease_duration

Period within which liveliness should be asserted.

On a DataWriter it represents the period it commits to signal its liveliness. On a DataReader it represents the period without assertion after which a DataWriter is considered inactive. By default, dds::c_TimeInfinite.


The documentation for this class was generated from the following file: