Namespace dds::core¶
-
namespace core¶
Typedefs
-
typedef dds::core::detail::InstanceHandle InstanceHandle¶
-
typedef std::vector<InstanceHandle> InstanceHandleSeq¶
-
typedef std::vector<uint8_t> ByteSeq¶
Use a std::vector<uint8_t> to hold a sequence of bytes.
-
typedef std::vector<std::string> StringSeq¶
Use a std::vector<std::string> to hold a sequence of bytes.
Functions
Variables
-
const int32_t LENGTH_UNLIMITED = -1¶
-
const null_type null¶
This is the DDS Null-Reference.
A dds reference object that doesn’t reference to anything can be compared with this object.
dds::domain::DomainParticipant participant = dds::core::null; ... if (participant == dds::core::null) { // The participant is not yet properly created. // Using it now will trigger the dds::core::NullReferenceError exception. }
-
template<typename T>
struct smart_ptr_traits¶
-
class Duration¶
- #include <Duration.hpp>
Duration represents a time interval and can -
Can be incremented by durations expressed as seconds, nanoseconds milliseconds, or Duration objects.
Can be converted to and from Durations expressed in milliseconds (or other units) as integer types.
Public Functions
-
explicit Duration(int32_t sec, uint32_t nanosec = 0)¶
Create a Duration elapsing a specific amount of time.
-
void sec(int64_t s)¶
Set number of seconds
- Parameters
s – number of seconds
-
void nanosec(uint32_t ns)¶
Set number of nanoseconds
- Parameters
ns – number of nanoseconds
-
int compare(const Duration &that) const¶
Returns an integer value for a comparison of two Durations: 1 if this Duration is greater than the comparator (that) -1 if the Duration is less than the comparator (that) 0 if the Duration matches the comparator (that)
- Parameters
that – Duration to compare
- Returns
comparison result
-
bool operator>(const Duration &that) const¶
Returns true if the Duration is greater than the comparator
- Parameters
that – Duration to compare
- Returns
comparison result
-
bool operator>=(const Duration &that) const¶
Returns true if the Duration is greater than or equal to the comparator
- Parameters
that – the Duration to compare
- Returns
true if that is larger than or equal to this
-
bool operator!=(const Duration &that) const¶
Returns true if the Duration is not equal to the comparator
- Parameters
that – Duration to compare
- Returns
comparison result
-
bool operator==(const Duration &that) const¶
Returns true if the Duration is equal to the comparator
- Parameters
that – Duration to compare
- Returns
comparison result
-
bool operator<=(const Duration &that) const¶
Returns true if the Duration is less than or equal to the comparator
- Parameters
that – Duration to compare
- Returns
comparison result
-
bool operator<(const Duration &that) const¶
Returns true if the Duration is less than the comparator
- Parameters
that – Duration to compare
- Returns
comparison result
-
int64_t to_millisecs() const¶
Returns this Duration in milliseconds.
- Returns
the duration in milliseconds
Public Static Functions
-
static const Duration from_microsecs(int64_t microseconds)¶
Create a Duration from a number of microseconds
- Parameters
microseconds – number of microseconds
-
class Exception¶
- #include <Exception.hpp>
Exception: base class for specified DDS Exceptions.
DDS PIM Return Code
DDS-PSM-CXX Exception Class
std C++ Parent Exception
RETCODE_OK
Normal return; no exception
N/A
RETCODE_NO_DATA
Normal return with informational state attached
N/A
RETCODE_ERROR
std::logic_error
RETCODE_BAD_PARAMETER
std::invalid_argument
RETCODE_TIMEOUT
std::runtime_error
RETCODE_UNSUPPORTED
std::logic_error
RETCODE_ALREADY_DELETED
std::logic_error
RETCODE_ILLEGAL_OPERATION
std::logic_error
RETCODE_NOT_ENABLED
std::logic_error
RETCODE_PRECONDITION_NOT_MET
std::logic_error
RETCODE_IMMUTABLE_POLICY
std::logic_error
RETCODE_INCONSISTENT_POLICY
std::logic_error
RETCODE_OUT_OF_RESOURCES
std::runtime_error
The DDS-PSM-Cxx maps error codes to C++ exceptions defined in the dds::core namespace and inheriting from a base Exception class and the appropriate standard C++ exception. Table 7.3 lists the mapping between error codes as defined in the DDS PIM and C++ exceptions as used in this specification. Exceptions have value semantics; this means that they must always have deep copy semantics. The full list of exceptions is included in the file dds/core/Exceptions.hpp.
Subclassed by dds::core::AlreadyClosedError, dds::core::Error, dds::core::IllegalOperationError, dds::core::ImmutablePolicyError, dds::core::InconsistentPolicyError, dds::core::InvalidArgumentError, dds::core::InvalidDataError, dds::core::InvalidDowncastError, dds::core::NotEnabledError, dds::core::NullReferenceError, dds::core::OutOfResourcesError, dds::core::PreconditionNotMetError, dds::core::TimeoutError, dds::core::UnsupportedError
Public Functions
-
virtual const char *what() const = 0¶
Retrieve information about the exception that was thrown.
Example
Exception information (of the NullReferenceError in this case)try { // Do something that will trigger a dds exception, like: dds::domain::DomainParticipant participant = dds::core::null; participant.domain_id(); } catch (const dds::core::Exception& e) { std::cout << e.what() << std::endl; }
Null reference: Reference[157] == dds::core::null ======================================================================================== Context : dds::domain::DomainParticipant::domain_id Date : Wed Oct 21 19:28:00 CET 2015 Node : DeLorean Process : flux_capacitor <15423> Thread : mr_fusion b6f25700 Internals : ReferenceImpl.hpp/157/V6.6.0 ---------------------------------------------------------------------------------------- Report : Null reference: Reference[157] == dds::core::null Internals : dds::core::Reference<DELEGATE>::delegate/ReferenceImpl.hpp/157
- Returns
Exception information
-
virtual const char *what() const = 0¶
-
class Error : public dds::core::Exception, public std::logic_error¶
- #include <Exception.hpp>
Exception: Generic, unspecified error.
-
class AlreadyClosedError : public dds::core::Exception, public std::logic_error¶
- #include <Exception.hpp>
Exception: The object target of this operation has already been closed.
-
class IllegalOperationError : public dds::core::Exception, public std::logic_error¶
- #include <Exception.hpp>
Exception: An operation was invoked on an inappropriate object or at an inappropriate time.
This is determined by policies set by the specification or the Service implementation.
There is no precondition that could be changed to make the operation succeed.
-
class ImmutablePolicyError : public dds::core::Exception, public std::logic_error¶
- #include <Exception.hpp>
Exception: Application attempted to modify an immutable QosPolicy.
-
class InconsistentPolicyError : public dds::core::Exception, public std::logic_error¶
- #include <Exception.hpp>
Exception: Application specified a set of policies that are not consistent with each other.
-
class InvalidArgumentError : public dds::core::Exception, public std::invalid_argument¶
- #include <Exception.hpp>
Exception: Application is passing an invalid argument.
-
class NotEnabledError : public dds::core::Exception, public std::logic_error¶
- #include <Exception.hpp>
Exception: Operation invoked on an Entity that is not yet enabled.
-
class OutOfResourcesError : public dds::core::Exception, public std::runtime_error¶
- #include <Exception.hpp>
Exception: Service ran out of the resources needed to complete the operation.
-
class PreconditionNotMetError : public dds::core::Exception, public std::logic_error¶
- #include <Exception.hpp>
Exception: A pre-condition for the operation was not met.
-
class TimeoutError : public dds::core::Exception, public std::runtime_error¶
- #include <Exception.hpp>
Exception: The operation timed out.
-
class UnsupportedError : public dds::core::Exception, public std::logic_error¶
- #include <Exception.hpp>
Exception: Unsupported operation.
This can only be thrown by operations that are optional.
-
class InvalidDowncastError : public dds::core::Exception, public std::runtime_error¶
- #include <Exception.hpp>
Exception: Application has attempted to cast incompatible types.
-
class NullReferenceError : public dds::core::Exception, public std::runtime_error¶
- #include <Exception.hpp>
Exception: Application used a null reference.
Very likely, the used DDS object is a dds::core::null object.
dds::domain::DomainParticipant participant = dds::core::null; try { participant.domain_id(); } catch (const dds::core::NullReferenceError& e) { std::cout << e.what() << std::endl; }
-
class InvalidDataError : public dds::core::Exception, public std::logic_error¶
- #include <Exception.hpp>
Exception: Application provided invalid data
-
template<typename T>
class external¶
-
template<typename T, template<typename Q> class DELEGATE>
class optional : public dds::core::Value<DELEGATE<T>>¶ - #include <Optional.hpp>
The optional class is used to wrap attributes annotated in the idl with the @optional annotation. This class provides a simple and safe way of accessing, setting and resetting the stored attribute.
IDL:
struct RadarTrack { string id; long x; long y; long z; //@Optional };
C++ Representation:
class RadarTrack { public: RadarTrack(); RadarTrack(const std::string& id, int32_t x, int32_t y, int32_t z); public: std::string& id() const; void id(const std::string& s); int32_t x() const; void x(int32_t v); int32_t y() const; void y(int32_t v); dds::core::optional<int32_t>& z() const; void z(int32_t v); void z(const dds::core::optional<int32_t>& z) };
-
template<typename DELEGATE>
class Reference¶ - #include <Reference.hpp>
Base class for reference-counted objects.
All objects that have a reference-type have an associated shallow (polymorphic) assignment operator that simply changes the value of the reference. Furthermore, reference-types are safe, meaning that under no circumstances can a reference point to an invalid object. At any single point in time a reference can either refer to the null object or to a valid object.
The semantics for Reference types is defined by the DDS-PSM-Cxx class dds::core::Reference. In the context of this specification the semantics implied by the ReferenceType is mandatory, yet the implementation supplied as part of this standard is provided to show one possible way of implementing this semantics.
List of reference types:
Entity
Condition
GuardCondition
ReadCondition
QueryCondition
Waitset
DomainParticipant
AnyDataWriter
Publisher
DataWriter
AnyDataReader
Subscriber
DataReader
SharedSamples
AnyTopic
Topic
Instances of reference types are created using C++ constructors. The trivial constructor is not defined for reference types; the only alternative to properly constructing a reference is to initialize it to a null reference by assigning dds::core::null.
Resource management for some reference types might involve relatively heavyweight operating-system resources (such as threads, mutexes, and network sockets) in addition to memory. These objects therefore provide a function close() that shall halt network communication (in the case of entities) and dispose of any appropriate operating-system resources.
Users of this PSM are recommended to call close on objects of all reference types once they are finished using them. In addition, implementations may automatically close objects that they deem to be no longer in use, subject to the following restrictions:
Any object to which the application has a direct reference (not including a WeakReference) is still in use.
Any object that has been explicitly retained is still in use.
The creator of any object that is still in use is itself still in use.
Subclassed by dds::core::TEntity< DELEGATE >, dds::core::TQosProvider< DELEGATE >, dds::core::cond::TCondition< DELEGATE >, dds::core::cond::TWaitSet< DELEGATE >, dds::sub::TQuery< DELEGATE >, dds::topic::TTopicDescription< DELEGATE >
Public Functions
-
explicit Reference(const Reference &ref)¶
Creates a Reference from another.
- Parameters
ref – the other reference
-
explicit Reference(Reference &&ref)¶
Creates a Reference from another.
- Parameters
ref – the other reference
-
template<typename D>
explicit Reference(const Reference<D> &ref)¶ Creates a Reference from other Reference type safely.
- Parameters
ref – the other reference
-
~Reference()¶
Destroys a Reference.
There might be an associated garbage collection activity when the current reference is not empty. When the underlaying delegate is referenced by another Reference object as well, then that delegate will not be destroyed.
-
template<typename R>
bool operator==(const R &ref) const¶ Compares two Reference objects and returns true if they are equal.
Equality is based on the referential equality of the object being pointed.
- Parameters
ref – the other Reference object
- Returns
true when equal
-
template<typename R>
bool operator!=(const R &ref) const¶ Compares two Reference objects and returns true if they are not equal.
Inequality is based on the referential inequality of the object being pointed to.
- Parameters
ref – the other Reference object
- Returns
true when not equal
-
template<typename D>
Reference &operator=(const Reference<D> &that)¶ Assign new referenced object to this dds reference.
There might be an associated garbage collection activity when the current reference is not empty.
- Returns
reference pointing to the new object.
-
template<typename R>
Reference &operator=(const R &rhs)¶ Assign new referenced object to this dds reference.
There might be an associated garbage collection activity when the current reference is not empty.
- Returns
reference pointing to the new object.
-
Reference &operator=(const Reference &other) = default¶
Assign new referenced object to this dds reference.
There might be an associated garbage collection activity when the current reference is not empty.
- Returns
reference pointing to the new object.
-
Reference &operator=(Reference &&other) = default¶
Assign new referenced object to this dds reference.
There might be an associated garbage collection activity when the current reference is not empty.
- Returns
reference pointing to the new object.
-
Reference &operator=(const null_type)¶
Special assignment operators that takes care of assigning dds::core::null to this reference.
When assigning null, there might be an associated garbage collection activity.
- Returns
reference pointing to a null object.
-
bool is_nil() const¶
Check if the referenced object is nil.
In other words, check if the reference is pointing to a null object.
- Returns
true if the referenced object is null.
-
bool operator==(const null_type) const¶
Special operator== used to check if this reference object equals the dds::core::null reference.
The null-check can be done like this:
if (r == dds::core::null) { // Do not use the dds reference object r in its current state }
- Returns
true if this reference is null.
-
bool operator!=(const null_type nil) const¶
Special operator!= used to check if this reference object does not equal the dds::core::null reference.
The non-null-check can be done like this:
if (r != dds::core::null) { // Use the dds reference object r }
- Returns
true if this reference is not null.
-
DELEGATE *operator->()¶
The operator->() is provided to be able to directly invoke functions on the delegate.
The decision to provide direct access to the delegate was motivated by the need for providing a way that was not invasive with respect to the CXXDDS API and yet would allow for vendor-specific extension. Thus vendor-specific extensions can be invoked on the Reference and on all its subclasses as follows:
my_dds_entity.standard_function(); my_dds_entity->vendor_specific_extension();
- Returns
a reference to delegate.
-
const DELEGATE *operator->() const¶
The operator->() is provided to be able to directly invoke functions on the delegate.
The decision to provide direct access to the delegate was motivated by the need for providing a way that was not invasive with respect to the CXXDDS API and yet would allow for vendor-specific extension. Thus vendor-specific extensions can be invoked on the Reference and on all its subclasses as follows:
my_dds_entity.standard_function(); my_dds_entity->vendor_specific_extension();
- Returns
a reference to delegate.
-
template<typename DELEGATE>
Reference(DELEGATE_T *p)¶
-
template<typename DELEGATE>
Reference(const DELEGATE_REF_T &p)¶
-
template<typename def, typename inner = typename def::Type>
class safe_enum : public def¶ - #include <SafeEnumeration.hpp>
safe_enum provides a wrapper for enumerated types in a typesafe manner.
safe_enums allow specification of the underlying type, do not implictly convert to integers, and resolve scoping issues.
Public Functions
-
inline safe_enum(type v)¶
-
inline safe_enum(type v)¶
-
template<typename DELEGATE>
class TEntity : public virtual dds::core::Reference<DELEGATE>¶ - #include <TEntity.hpp>
This class is the abstract base class for all the DCPS objects.
This class is the abstract base class for all of the DCPS objects that support QoS policies a listener and a status condition:
dds::domain::DomainParticipant
dds::sub::Subscriber
dds::pub::Publisher
In the ISO C++ PSM each DDS entity behaves like a polymorphic reference in that it automatically manages its resource and it can be safely assigned up and down the DDS Entity type hierarchy.
Subclassed by dds::pub::TAnyDataWriter< DELEGATE< T > >, dds::sub::TAnyDataReader< DELEGATE< T > >, dds::topic::TAnyTopic< DELEGATE< T > >, dds::domain::TDomainParticipant< DELEGATE >, dds::pub::TAnyDataWriter< DELEGATE >, dds::pub::TPublisher< DELEGATE >, dds::sub::TAnyDataReader< DELEGATE >, dds::sub::TSubscriber< DELEGATE >, dds::topic::TAnyTopic< DELEGATE >
Public Functions
-
void enable()¶
Enable entity.
This operation enables the Entity. Entity objects can be created either enabled or disabled. This is controlled by the value of the dds::core::policy::EntityFactory QoS policy on the corresponding factory for the Entity.
Enabled entities are immediately activated at creation time meaning all their immutable QoS settings can no longer be changed. Disabled Entities are not yet activated, so it is still possible to change there immutable QoS settings. However, once activated the immutable QoS settings can no longer be changed.
Creating disabled entities can make sense when the creator of the Entity does not yet know which QoS settings to apply, thus allowing another piece of code to set the QoS later on.
The default setting of dds::core::policy::EntityFactory is such that, by default, it is not necessary to explicitly call enable on newly- created entities.
The enable operation is idempotent. Calling enable on an already- enabled Entity does not raise exceptions and has no effect.
If an Entity has not yet been enabled, the only operations that can be invoked on it are: the ones to set, get or copy the QosPolicy settings, the ones that set (or get) the listener, the ones that get the StatusCondition, the get_status_changes operation (although the status of a disabled entity never changes), and the ‘factory’ operations that create, delete or lookup other Entities. Other operations will throw the exception dds::core::NotEnabledError.
Entities created from a factory that is disabled are created disabled regardless of the setting of the dds::core::policy::EntityFactory Qos policy. Calling enable on an Entity whose factory is not enabled will fail and throw an dds::core::PreconditionNotMetError exception.
If the dds::core::policy::EntityFactory QoS policy has autoenable_created_entities set to TRUE, the enable operation on the factory will automatically enable all entities created from the factory.
The Listeners associated with an entity are not called until the entity is enabled. Conditions associated with an entity that is not enabled are inactive; that is, they have a trigger_value==false (dds::core::cond::Condition and dds::core::cond::WaitSet).
eg.
dds::domain::qos::DomainParticipantQos dpq; dpq << dds::core::policy::EntityFactory::ManuallyEnable(); ... dds::sub::DataReader<Foo::Bar> dr(dp, topic, drqos); dr.enable();
- Throws
dds::core::PreconditionNotMetError – Entities’ factory is not enabled.
-
const dds::core::status::StatusMask status_changes()¶
This operation returns a mask with the communication statuses in the Entity that are “triggered”.
This operation retrieves the list of communication statuses in the Entity that are triggered. That is the set of communication statuses whose value have changed since the last time the application called this operation. This operation shows whether a change has occurred even when the status seems unchanged because the status changed back to the original status.
When the Entity is first created or if the Entity is not enabled, all communication statuses are in the “un-triggered” state so the mask returned by the operation is empty.
The result value is a bit mask in which each bit shows which value has changed. The relevant bits represent one of the following statuses:
When the entity is first created, or if the entity is not enabled, all communication statuses are in the untriggered state so the list returned by the status_changes operation will be empty.
Each status bit is declared as a constant and can be used in an AND operation to check the status bit against the result of type StatusMask. Not all statuses are relevant to all Entity objects. See the respective Listener interfaces for each Entity for more information.
The list of statuses returned by the status_changes operation refers to the statuses that are triggered on the Entity itself, and does not include statuses that apply to contained entities.
- Returns
dds::core::status::StatusMask a bit mask in which each bit shows which value has changed.
-
const dds::core::InstanceHandle instance_handle() const¶
This operation returns the InstanceHandle_t that represents the Entity.
The relevant state of some Entity objects are distributed using built-in topics. Each built-in topic sample represents the state of a specific Entity and has a unique instance_handle. This operation returns the instance_handle of the built-in topic sample that represents the specified Entity.
Some Entities (dds::pub::Publisher and dds::sub::Subscriber) do not have a corresponding built-in topic sample, but they still have an instance_handle that uniquely identifies the Entity. The instance_handles obtained this way can also be used to check whether a specific Entity is located in a specific DomainParticipant (
dds::domain::DomainParticipant::contains_entity()).- Returns
dds::core::InstanceHandle Result value is the instance_handle of the built-in topic sample that represents the state of this Entity.
-
void close()¶
This function closes the entity and releases related resources.
Resource management for some reference types might involve relatively heavyweight operating- system resources — such as e.g., threads, mutexes, and network sockets — in addition to memory. These objects therefore provide a method close() that shall halt network communication (in the case of entities) and dispose of any appropriate operating-system resources.
Users of this PSM are recommended to call close on objects of all reference types once they are finished using them. In addition, implementations may automatically close objects that they deem to be no longer in use, subject to the following restrictions:
Any object to which the application has a direct reference is still in use.
Any object that has been explicitly retained is still in use
The creator of any object that is still in use is itself still in use.
-
void retain()¶
Retain the Entity, even when it goes out of scope.
This function indicates that references to this object may go out of scope but that the application expects to look it up again later. Therefore the Service must consider this object to be still in use and may not close it automatically.
-
template<typename DELEGATE>
class TEntityQos : public dds::core::Value<DELEGATE>¶ - #include <TEntityQos.hpp>
QoS Container.
Acts as a container for Qos policies allowing all the policies of an entity to be set and retrieved as a unit.
For more information see Infrastructure Module and Supported Quality of Service
Public Functions
-
TEntityQos()¶
Create default QoS.
-
TEntityQos(const TEntityQos &other)¶
Create copied QoS.
- Parameters
other – the QoS to copy.
-
TEntityQos(TEntityQos &&other)¶
Create moved QoS.
- Parameters
other – the QoS to move.
-
TEntityQos<DELEGATE> &operator=(const TEntityQos<DELEGATE> &other) = default¶
Copy to this QoS.
- Parameters
other – the QoS to copy.
- Returns
reference to the Qos which was copied to.
-
TEntityQos<DELEGATE> &operator=(TEntityQos<DELEGATE> &&other) = default¶
Move to this QoS.
- Parameters
other – the QoS to move.
- Returns
reference to the Qos which was moved to.
-
template<typename T>
TEntityQos(const TEntityQos<T> &qos)¶ Create/copy QoS from different QoS type.
- Parameters
qos – the QoS to copy policies from.
-
template<typename POLICY>
TEntityQos &policy(const POLICY &p)¶ Generic function for setting a policy applicable to this QoS object. Available policies depend on the actual instantiation of the template class, which might be DomainParticipantQos, TopicQos, PublisherQos, etc.
- Parameters
p – the policy to be set for this QoS instance.
-
template<typename POLICY>
const POLICY &policy() const¶ Generic function for obtaining the value of a specific policy belonging to this QoS instance.
- Returns
policy
-
template<typename POLICY>
POLICY &policy()¶ Generic function for obtaining the value of a specific policy belonging to this QoS instance.
- Returns
policy
-
template<typename POLICY>
TEntityQos &operator<<(const POLICY &p)¶ Generic function for setting a policy applicable to this QoS object. Available policies depend on the actual instantiation of the template class, which might be DomainParticipantQos, TopicQos, PublisherQos, etc.
- Parameters
p – the policy to be set for this QoS instance.
-
template<typename POLICY>
const TEntityQos &operator>>(POLICY &p) const¶ Generic function for obtaining the value of a specific policy belonging to this QoS instance.
- Returns
policy
-
template<typename T>
TEntityQos<DELEGATE> &operator=(const TEntityQos<T> &other)¶ Generic function for setting a policy applicable to this QoS object. Available policies depend on the actual instantiation of the template class, which might be DomainParticipantQos, TopicQos, PublisherQos, etc.
- Parameters
other – the TEntityQos to set
-
template<typename POLICY>
TEntityQos<DELEGATE> &policy(const POLICY &p)¶
-
template<typename POLICY>
TEntityQos<DELEGATE> &operator<<(const POLICY &p)¶
-
template<typename POLICY>
const TEntityQos<DELEGATE> &operator>>(POLICY &p) const¶
-
TEntityQos()¶
-
class Time¶
- #include <Time.hpp>
Time represents a time value and can:
Be incremented by Duration expressed as seconds, nanoseconds, milliseconds, or Duration objects.
Be converted to and from Times expressed in milliseconds (or other units) as integer types.
Public Functions
-
int64_t sec() const¶
- Returns
number of seconds
-
void sec(int64_t s)¶
Set number of seconds
- Parameters
s – number of seconds
-
uint32_t nanosec() const¶
- Returns
number of nanoseconds
-
void nanosec(uint32_t ns)¶
Set number of nanoseconds
- Parameters
ns – number of nanoseconds
-
int compare(const Time &that) const¶
Returns an integer indicating the result of a comparison of two Times: 1 if this Time is greater than the comparator (that) -1 if the Time is less than the comparator (that) 0 if the Time matches the comparator (that)
- Parameters
that – Time to compare
- Returns
comparison result
Public Static Functions
-
static const Time from_microsecs(int64_t microseconds)¶
Create a Time from a number of microseconds
- Parameters
microseconds – number of microseconds
-
template<typename DELEGATE>
class TInstanceHandle : public dds::core::Value<DELEGATE>¶ - #include <TInstanceHandle.hpp>
Class to hold the handle associated with in sample instance.
Public Functions
-
TInstanceHandle()¶
Create an nil instance handle.
-
TInstanceHandle(const dds::core::null_type &nullHandle)¶
Create an nil instance handle.
- Parameters
nullHandle – placeholder
-
TInstanceHandle(const TInstanceHandle &other)¶
Copy an existing InstanceHandle
- Parameters
other – InstanceHandle to copy
-
TInstanceHandle(TInstanceHandle &&other)¶
Move an existing InstanceHandle
- Parameters
other – InstanceHandle to move
-
TInstanceHandle &operator=(const TInstanceHandle &that)¶
Copy-assign an existing InstanceHandle to this InstanceHandle
- Parameters
that – The TInstanceHandle to assign to this
-
TInstanceHandle &operator=(TInstanceHandle &&that)¶
Move-assign an existing InstanceHandle to this InstanceHandle
- Parameters
that – The TInstanceHandle to assign to this
-
bool operator==(const TInstanceHandle &that) const¶
Compare this InstanceHandle to another InstanceHandle
- Parameters
that – The TInstanceHandle to compare
- Returns
true if they match
-
bool operator<(const TInstanceHandle &that) const¶
Compare this InstanceHandle to another InstanceHandle
- Parameters
that – The TInstanceHandle to compare
- Returns
true if this is less than that
-
bool operator>(const TInstanceHandle &that) const¶
Compare this InstanceHandle to another InstanceHandle
- Parameters
that – The TInstanceHandle to compare
- Returns
true if this is greater than that
-
bool is_nil() const¶
Check if the InstanceHandle is nil.
- Returns
true if the InstanceHandle is nil
Public Static Functions
-
static const TInstanceHandle nil()¶
Create an nil instance handle.
- Returns
a nil InstanceHandle
-
TInstanceHandle()¶
-
template<typename DELEGATE>
class TQosProvider : public dds::core::Reference<DELEGATE>¶ - #include <TQosProvider.hpp>
The QosProvider API allows users to specify the QoS settings of their DCPS entities outside of application code in XML.
The QosProvider is delivered as part of the DCPS API.
See also
for more information: QoS Provider extensive information.
Public Functions
-
explicit TQosProvider(const std::string &uri, const std::string &profile)¶
Constructs a new QosProvider based on the provided uri and profile.
A QosProvider instance that is instantiated with all profiles and/or QoS’s loaded from the location specified by the provided uri.
Initialization of the QosProvider will fail under the following conditions:
No uri is provided.
The resource pointed to by uri cannot be found.
The content of the resource pointed to by uri is malformed (e.g., malformed XML). When initialization fails (for example, due to a parse error or when the resource identified by uri cannot be found), then PreconditionNotMetError will be thrown.
Look here for more information.
- Parameters
uri – A Uniform Resource Identifier (URI) that points to the location where the QoS profile needs to be loaded from. Currently only URI’s with a ‘file’ scheme that point to an XML file are supported. If profiles and/or QoS settings are not uniquely identifiable by name within the resource pointed to by uri, a random one of them will be stored.
profile – The name of the QoS profile within the xml file that serves as the default QoS profile for the get qos operations.
- Throws
dds::core::PreconditionNotMetError – When multiple thread try to invoke the function concurrently.
-
explicit TQosProvider(const std::string &uri)¶
Constructs a new QosProvider based on the provided uri.
A QosProvider instance that is instantiated with all profiles and/or QoS’s loaded from the location specified by the provided uri.
Initialization of the QosProvider will fail under the following conditions:
No uri is provided.
The resource pointed to by uri cannot be found.
The content of the resource pointed to by uri is malformed (e.g., malformed XML). When initialization fails (for example, due to a parse error or when the resource identified by uri cannot be found), then PreconditionNotMetError will be thrown.
Look here for more information.
- Parameters
uri – A Uniform Resource Identifier (URI) that points to the location where the QoS profile needs to be loaded from. Currently only URI’s with a ‘file’ scheme that point to an XML file are supported. If profiles and/or QoS settings are not uniquely identifiable by name within the resource pointed to by uri, a random one of them will be stored.
- Throws
dds::core::PreconditionNotMetError – When multiple thread try to invoke the function concurrently.
-
dds::domain::qos::DomainParticipantQos participant_qos()¶
Resolves the DomainParticipantQos from the uri this QosProvider is associated with.
- Throws
dds::core::PreconditionNotMetError – If no DomainParticipantQos can be found within the uri associated with the QosProvider.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
- Returns
DomainParticipantQos from the given URI (and profile)
-
dds::domain::qos::DomainParticipantQos participant_qos(const std::string &id)¶
Resolves the DomainParticipantQos identified by the id from the uri this QosProvider is associated with.
- Parameters
id – The fully-qualified name that identifies a QoS within the uri associated with the QosProvider or a name that identifies a QoS within the uri associated with the QosProvider instance relative to its default QoS profile. Id’s starting with ‘::’ are interpreted as fully-qualified names and all others are interpreted as names relative to the default QoS profile of the QosProvider instance. When id is NULL it is interpreted as a non-named QoS within the default QoS profile associated with the QosProvider.
- Throws
dds::core::PreconditionNotMetError – If no DomainParticipantQos that matches the provided id can be found within the uri associated with the QosProvider.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
- Returns
DomainParticipantQos from the given URI (and profile) using the id
-
dds::topic::qos::TopicQos topic_qos()¶
Resolves the TopicQos from the uri this QosProvider is associated with.
- Throws
dds::core::PreconditionNotMetError – If no TopicQos can be found within the uri associated with the QosProvider.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
- Returns
TopicQos from the given URI (and profile)
-
dds::topic::qos::TopicQos topic_qos(const std::string &id)¶
Resolves the TopicQos identified by the id from the uri this QosProvider is associated with.
- Parameters
id – The fully-qualified name that identifies a QoS within the uri associated with the QosProvider or a name that identifies a QoS within the uri associated with the QosProvider instance relative to its default QoS profile. Id’s starting with ‘::’ are interpreted as fully-qualified names and all others are interpreted as names relative to the default QoS profile of the QosProvider instance. When id is NULL it is interpreted as a non-named QoS within the default QoS profile associated with the QosProvider.
- Throws
dds::core::PreconditionNotMetError – If no TopicQos that matches the provided id can be found within the uri associated with the QosProvider.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
- Returns
TopicQos from the given URI (and profile) using the id
-
dds::sub::qos::SubscriberQos subscriber_qos()¶
Resolves the SubscriberQos from the uri this QosProvider is associated with.
- Throws
dds::core::PreconditionNotMetError – If no SubscriberQos can be found within the uri associated with the QosProvider.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
- Returns
SubscriberQos from the given URI (and profile)
-
dds::sub::qos::SubscriberQos subscriber_qos(const std::string &id)¶
Resolves the SubscriberQos identified by the id from the uri this QosProvider is associated with.
- Parameters
id – The fully-qualified name that identifies a QoS within the uri associated with the QosProvider or a name that identifies a QoS within the uri associated with the QosProvider instance relative to its default QoS profile. Id’s starting with ‘::’ are interpreted as fully-qualified names and all others are interpreted as names relative to the default QoS profile of the QosProvider instance. When id is NULL it is interpreted as a non-named QoS within the default QoS profile associated with the QosProvider.
- Throws
dds::core::PreconditionNotMetError – If no SubscriberQos that matches the provided id can be found within the uri associated with the QosProvider.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
- Returns
SubscriberQos from the given URI (and profile) using the id
-
dds::sub::qos::DataReaderQos datareader_qos()¶
Resolves the DataReaderQos from the uri this QosProvider is associated with.
- Throws
dds::core::PreconditionNotMetError – If no DataReaderQos can be found within the uri associated with the QosProvider.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
- Returns
DataReadertQos from the given URI (and profile)
-
dds::sub::qos::DataReaderQos datareader_qos(const std::string &id)¶
Resolves the DataReaderQos identified by the id from the uri this QosProvider is associated with.
- Parameters
id – The fully-qualified name that identifies a QoS within the uri associated with the QosProvider or a name that identifies a QoS within the uri associated with the QosProvider instance relative to its default QoS profile. Id’s starting with ‘::’ are interpreted as fully-qualified names and all others are interpreted as names relative to the default QoS profile of the QosProvider instance. When id is NULL it is interpreted as a non-named QoS within the default QoS profile associated with the QosProvider.
- Throws
dds::core::PreconditionNotMetError – If no DataReaderQos that matches the provided id can be found within the uri associated with the QosProvider.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
- Returns
DataReaderQos from the given URI (and profile) using the id
-
dds::pub::qos::PublisherQos publisher_qos()¶
Resolves the PublisherQos from the uri this QosProvider is associated with.
- Throws
dds::core::PreconditionNotMetError – If no PublisherQos can be found within the uri associated with the QosProvider.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
- Returns
PublisherQos from the given URI (and profile)
-
dds::pub::qos::PublisherQos publisher_qos(const std::string &id)¶
Resolves the PublisherQos identified by the id from the uri this QosProvider is associated with.
- Parameters
id – The fully-qualified name that identifies a QoS within the uri associated with the QosProvider or a name that identifies a QoS within the uri associated with the QosProvider instance relative to its default QoS profile. Id’s starting with ‘::’ are interpreted as fully-qualified names and all others are interpreted as names relative to the default QoS profile of the QosProvider instance. When id is NULL it is interpreted as a non-named QoS within the default QoS profile associated with the QosProvider.
- Throws
dds::core::PreconditionNotMetError – If no PublisherQos that matches the provided id can be found within the uri associated with the QosProvider.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
- Returns
PublisherQos from the given URI (and profile) using the id
-
dds::pub::qos::DataWriterQos datawriter_qos()¶
Resolves the DataWriterQos from the uri this QosProvider is associated with.
- Throws
dds::core::PreconditionNotMetError – If no DataWriterQos can be found within the uri associated with the QosProvider.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
- Returns
DataWriterQos from the given URI (and profile)
-
dds::pub::qos::DataWriterQos datawriter_qos(const std::string &id)¶
Resolves the DataWriterQos identified by the id from the uri this QosProvider is associated with.
- Parameters
id – The fully-qualified name that identifies a QoS within the uri associated with the QosProvider or a name that identifies a QoS within the uri associated with the QosProvider instance relative to its default QoS profile. Id’s starting with ‘::’ are interpreted as fully-qualified names and all others are interpreted as names relative to the default QoS profile of the QosProvider instance. When id is NULL it is interpreted as a non-named QoS within the default QoS profile associated with the QosProvider.
- Throws
dds::core::PreconditionNotMetError – If no DataWriterQos that matches the provided id can be found within the uri associated with the QosProvider.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
- Returns
DataWriterQos from the given URI (and profile) using the id
-
explicit TQosProvider(const std::string &uri, const std::string &profile)¶
-
class null_type¶
- #include <types.hpp>
This class is used to create dds::core::null objects.
-
template<typename D>
class Value¶ - #include <Value.hpp>
This class is the base for various value-type dds objects.
QoS, Policy, Statuses, and Topic samples are all modeled as value-types.
All objects that have a value-type have a deep-copy assignment and copy construction semantics. It should also be pointed out that value-types are not ‘pure-value-types’ in the sense that they are immutable (as in functional programming languages).
The DDS-PSM-Cxx makes value-types mutable to limit the number of copies as well as to limit the time-overhead necessary to change a value-type (note that for immutable value-types the only form of change is to create a new value-type).
Subclassed by dds::core::policy::TDeadline< D >, dds::core::policy::TDestinationOrder< D >, dds::core::policy::TDurability< D >, dds::core::policy::TEntityFactory< D >, dds::core::policy::TGroupData< D >, dds::core::policy::THistory< D >, dds::core::policy::TLatencyBudget< D >, dds::core::policy::TLifespan< D >, dds::core::policy::TLiveliness< D >, dds::core::policy::TPSMXInstances< D >, dds::core::policy::TPartition< D >, dds::core::policy::TPresentation< D >, dds::core::policy::TQosPolicyCount< D >, dds::core::policy::TReaderDataLifecycle< D >, dds::core::policy::TReliability< D >, dds::core::policy::TResourceLimits< D >, dds::core::policy::TTimeBasedFilter< D >, dds::core::policy::TTopicData< D >, dds::core::policy::TTransportPriority< D >, dds::core::policy::TUserData< D >, dds::core::policy::TWriterBatching< D >, dds::core::policy::TWriterDataLifecycle< D >, dds::core::status::TInconsistentTopicStatus< D >, dds::core::status::TLivelinessChangedStatus< D >, dds::core::status::TLivelinessLostStatus< D >, dds::core::status::TOfferedDeadlineMissedStatus< D >, dds::core::status::TOfferedIncompatibleQosStatus< D >, dds::core::status::TPublicationMatchedStatus< D >, dds::core::status::TRequestedDeadlineMissedStatus< D >, dds::core::status::TRequestedIncompatibleQosStatus< D >, dds::core::status::TSampleLostStatus< D >, dds::core::status::TSampleRejectedStatus< D >, dds::core::status::TSubscriptionMatchedStatus< D >, dds::topic::TBuiltinTopicKey< D >, dds::topic::TFilter< D >, dds::topic::TParticipantBuiltinTopicData< D >, dds::topic::TPublicationBuiltinTopicData< D >, dds::topic::TSubscriptionBuiltinTopicData< D >, dds::topic::TTopicBuiltinTopicData< D >
Public Functions
-
bool operator==(const Value &other) const¶
Compare this Value with another Value
- Parameters
other – Value
- Returns
true if equal
-
bool operator!=(const Value &other) const¶
Compare this Value with another Value
- Parameters
other – Value
- Returns
true if not equal
-
D *operator->()¶
The operator->() is provided to be able to directly invoke functions on the delegate.
The decision to provide direct access to the delegate was motivated by the need for providing a way that was not invasive with respect to the CXXDDS API and yet would allow for vendor-specific extension. Thus vendor-specific extensions can be invoked on the Value and on all its subclasses as follows:
my_dds_value.standard_function(); my_dds_value->vendor_specific_extension();
- Returns
a reference to delegate.
-
const D *operator->() const¶
The operator->() is provided to be able to directly invoke functions on the delegate.
The decision to provide direct access to the delegate was motivated by the need for providing a way that was not invasive with respect to the CXXDDS API and yet would allow for vendor-specific extension. Thus vendor-specific extensions can be invoked on the Value and on all its subclasses as follows:
my_dds_value.standard_function(); my_dds_value->vendor_specific_extension();
- Returns
a reference to delegate.
-
bool operator==(const Value &other) const¶
-
template<typename T>
class WeakReference¶ - #include <WeakReference.hpp>
The WeakReference class enables you to maintain a weak reference to a DDS reference type.
The existence of a weak link will not prevent the garbage collection of the reference type.
Public Functions
-
WeakReference()¶
Creates a weak reference without an referenced dds object.
-
WeakReference(const T &t)¶
Creates a weak reference for the reference type passed as argument.
- Parameters
t – dds object the new weak reference will refer to
-
bool expired()¶
Checks whether the underlying reference has been deleted.
- Returns
true if the underlying reference has expired, false otherwise
-
WeakReference()¶
-
namespace cond¶
Typedefs
-
typedef dds::core::cond::detail::GuardCondition GuardCondition¶
-
typedef detail::StatusCondition StatusCondition¶
-
template<typename DELEGATE>
class TGuardCondition : public dds::core::cond::TCondition<DELEGATE>¶ - #include <TGuardCondition.hpp>
A GuardCondition object is a specific Condition whose trigger_value is completely under the control of the application.
When a GuardCondition is initially created, the trigger_value is FALSE.
The purpose of the GuardCondition is to provide the means for the application to manually triggering a WaitSet to stop waiting. This is accomplished by attaching the GuardCondition to the WaitSet and then setting the trigger_value by means of the set trigger_value operation.
See the WaitSet examplesdds::core::cond::GuardCondition guard; dds::core::cond::WaitSet waitset; waitset.attach_condition(guard); waitset.wait(); ... // To wakeup waitset, do in another thread: guard.trigger_value(true);
for more examples.
Although the WaitSet examples use the StatusCondition, the basic usage of this Condition with a WaitSet is the same.
See also
dds::core::cond::Condition
See also
for more information: WaitSet concept
See also
for more information: WaitSet examples
Public Functions
-
TGuardCondition()¶
Create a dds::core::cond::GuardCondition.
The GuardCondition can then be added to a dds::core::cond::WaitSet so that the application can manually wake up a thread that is blocked on that WaitSet.
-
template<typename FUN>
TGuardCondition(FUN functor)¶ Create a dds::core::cond::GuardCondition.
The GuardCondition can then be added to a dds::core::cond::WaitSet so that the application can manually wake up a thread that is blocked on that WaitSet.
The supplied functor will be called when this GuardCondition is triggered and either the inherited dds::core::cond::Condition::dispatch() is called or the dds::core::cond::WaitSet::dispatch() on the WaitSet to which this GuardCondition is attached to.
-
void trigger_value(bool value)¶
This operation sets the trigger_value of the GuardCondition.
A GuardCondition object is a specific Condition which trigger_value is completely under the control of the application. This operation must be used by the application to manually wake-up a WaitSet. This operation sets the trigger_value of the GuardCondition to the parameter value. The GuardCondition is directly created using the GuardCondition constructor. When a GuardCondition is initially created, the trigger_value is FALSE.
-
bool trigger_value()¶
This operation retrieves the trigger_value of the Condition.
A Condition has a trigger_value that can be TRUE or FALSE and is set by the Data Distribution Service (except a GuardCondition). This operation returns the trigger_value of the Condition.
-
TGuardCondition()¶
-
template<typename DELEGATE>
class TStatusCondition : public dds::core::cond::TCondition<DELEGATE>¶ - #include <TStatusCondition.hpp>
A StatusCondition object is a specific Condition that is associated with each Entity.
Entity objects that have status attributes also have a StatusCondition, access is provided to the application by the get_statuscondition operation. The communication statuses whose changes can be communicated to the application depend on the Entity. The following table shows the relevant statuses for each Entity.
The inherited dds::core::cond::Condition::trigger_value() of the StatusCondition depends on the communication statuses of that Entity (e.g., missed deadline) and also depends on the value of the dds::core::status::StatusMask.
A StatusCondition can be attached to a WaitSet in order to allow an application to suspend until the trigger_value has become TRUE.
The trigger_value of a StatusCondition will be TRUE if one of the enabled StatusChangedFlags is set. That is, trigger_value==FALSE only if all the values of the StatusChangedFlags are FALSE.
The sensitivity of the StatusCondition to a particular communication status is controlled by the list of enabled_statuses set on the condition by means of dds::core::cond::StatusCondition::enabled_statuses(const ::dds::core::status::StatusMask& status) When the enabled_statuses are not changed by that operation, all statuses are enabled by default.
See the WaitSet examples for examples how to use this Condition.
See also
dds::core::cond::Condition
See also
for more information: Status concept
See also
for more information: WaitSet concept
See also
for more information: WaitSet examples
Public Functions
-
TStatusCondition(const dds::core::Entity &e)¶
Create a dds::core::cond::StatusCondition associated with an Entity.
The StatusCondition can then be added to a dds::core::cond::WaitSet so that the application can wait for specific status changes that affect the Entity.
-
template<typename FUN>
TStatusCondition(const dds::core::Entity &e, FUN functor)¶ Create a dds::core::cond::StatusCondition associated with an Entity.
The StatusCondition can then be added to a dds::core::cond::WaitSet so that the application can wait for specific status changes that affect the Entity.
The supplied functor will be called when this StatusCondition is triggered and either the inherited dds::core::cond::Condition::dispatch() is called or the dds::core::cond::WaitSet::dispatch() on the WaitSet to which this StatusCondition is attached to.
-
void enabled_statuses(const ::dds::core::status::StatusMask &status) const¶
This operation sets the list of communication statuses that are taken into account to determine the trigger_value of the StatusCondition.
The inherited dds::core::cond::Condition::trigger_value() of the StatusCondition depends on the communication status of that Entity (e.g., missed deadline, loss of information, etc.), ‘filtered’ by the set of enabled_statuses on the StatusCondition.
This operation sets the list of communication statuses that are taken into account to determine the trigger_value of the StatusCondition. This operation may change the trigger_value of the StatusCondition.
dds::core::cond::WaitSet objects behaviour depend on the changes of the trigger_value of their attached Conditions. Therefore, any WaitSet to which the StatusCondition is attached is potentially affected by this operation. If this function is not invoked, the default list of enabled_statuses includes all the statuses.
The result value is a bit mask in which each bit shows which value has changed. The relevant bits represent one of the following statuses:
Each status bit is declared as a constant and can be used in an AND operation to check the status bit against the result of type StatusMask. Not all statuses are relevant to all Entity objects. See the respective Listener interfaces for each Entity for more information.
- Parameters
status – A bit mask in which each bit sets the status which is taken into account for the StatusCondition.the enabled statuses.
- Throws
dds::core::AlreadyClosedError –
-
const ::dds::core::status::StatusMask enabled_statuses() const¶
This operation returns the list of enabled communication statuses of the StatusCondition.
The inherited dds::core::cond::Condition::trigger_value() of the StatusCondition depends on the communication status of that Entity (e.g., missed deadline, loss of information, etc.), ‘filtered’ by the set of enabled_statuses on the StatusCondition.
This operation returns the list of communication statuses that are taken into account to determine the trigger_value of the StatusCondition. This operation returns the statuses that were explicitly set on the last call to dds::core::cond::StatusCondition::enabled_statuses(const ::dds::core::status::StatusMask& status) const or, if enabled_statuses(status) was never called, the default list.
The result value is a bit mask in which each bit shows which value has changed. The relevant bits represent one of the following statuses:
Each status bit is declared as a constant and can be used in an AND operation to check the status bit against the result of type StatusMask. Not all statuses are relevant to all Entity objects. See the respective Listener interfaces for each Entity for more information.
- Throws
- Returns
dds::core::status::StatusMask A bit mask in which each bit shows which status is taken into account for the StatusCondition.
-
const dds::core::Entity &entity() const¶
This operation returns the Entity associated with the StatusCondition
Note that there is exactly one Entity associated with each StatusCondition.
- Throws
dds::core::AlreadyClosedError –
- Returns
dds::core::Entity The Entity associated with the StatusCondition.
-
TStatusCondition(const dds::core::Entity &e)¶
-
template<typename DELEGATE>
class TCondition : public virtual dds::core::Reference<DELEGATE>¶ - #include <TCondition.hpp>
This class is the base class for all the conditions that may be attached to a dds::core::cond::WaitSet.
This base class is specialized in three classes by the Data Distribution Service:
dds::core::cond::GuardCondition
dds::core::cond::StatusCondition
dds::sub::cond::ReadCondition
dds::sub::cond::QueryCondition
Each Condition has a trigger_value that can be TRUE or FALSE and is set by the Data Distribution Service (except a GuardCondition) depending on the evaluation of the Condition.
See also
for more information: Status concept
See also
for more information: WaitSet concept
Subclassed by dds::core::cond::TGuardCondition< DELEGATE >, dds::core::cond::TStatusCondition< DELEGATE >, dds::sub::cond::TReadCondition< DELEGATE >
Public Functions
-
template<typename Functor>
void handler(Functor func)¶ Registers a functor as custom handler with this Condition.
The supplied functor will be called when this Condition is triggered and either the dds::core::cond::Condition::dispatch() is called or the dds::core::cond::WaitSet::dispatch() on the WaitSet to which this Condition is attached to.
-
void reset_handler()¶
Resets the handler for this Condition.
After the invocation of this function no handler will be registered with this Condition.
-
void dispatch()¶
Dispatches the functor that have been registered with the Condition.
The Condition has to have been triggered for the functor will be called by this function.
-
bool trigger_value() const¶
This operation retrieves the trigger_value of the Condition.
A Condition has a trigger_value that can be TRUE or FALSE and is set by the Data Distribution Service (except a GuardCondition). This operation returns the trigger_value of the Condition.
-
template<typename DELEGATE>
class TWaitSet : public dds::core::Reference<DELEGATE>¶ - #include <TWaitSet.hpp>
A WaitSet object allows an application to wait until one or more of the attached Condition objects has a trigger_value of TRUE or else until the timeout expires.
A WaitSet is not necessarily associated with a single DomainParticipant and could be used to wait for Condition objects associated with different DomainParticipant objects.
When using the wait() operation, the triggered Conditions are returned in a list.
// Create a Condition to attach to a Waitset dds::core::cond::StatusCondition readerSC = dds::core::cond::StatusCondition(reader); readerSC.enabled_statuses(dds::core::status::StatusMask::data_available()); // Create WaitSet and attach Condition dds::core::cond::WaitSet waitset; waitset.attach_condition(readerSC); // or waitset += readerSC; dds::core::cond::WaitSet::ConditionSeq conditions; while(true) { // Wait for any Condition to trigger. conditions = waitset.wait(); // Loop through the triggered conditions. for (int i=0; i < conditions.size(); i++) { // Handle data_available when right Condition triggered. if (conditions[i] == readerSC) { // Read samples from the DataReader } } }
When using the dispatch() operation, the Functors of the triggered Conditions will be called.
// Functor to add to a Condition class FunctorStatusCondition { public: void operator()(const dds::core::cond::StatusCondition& condition) { // Possibly get reader from the condition and read some samples. } }; FunctorStatusCondition functor; // Create a Condition with functor to attach to a Waitset dds::core::cond::StatusCondition readerSC = dds::core::cond::StatusCondition(reader, functor); readerSC.enabled_statuses(dds::core::status::StatusMask::data_available()); // Create WaitSet and attach Condition dds::core::cond::WaitSet waitset; waitset.attach_condition(readerSC); // or waitset += readerSC; while(true) { // Wait for any Condition to trigger. // The functors of the Conditions are automatically called // when the Condition triggers. waitset.dispatch(); }
See also
for more information: WaitSet concept
Public Functions
-
TWaitSet()¶
Create a WaitSet instance.
- Throws
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
-
const ConditionSeq wait(const dds::core::Duration &timeout)¶
This operation allows an application thread to wait for the occurrence of at least one of the conditions that is attached to the WaitSet.
This operation allows an application thread to wait for the occurrence of certain Conditions. If none of the Conditions attached to the WaitSet have a trigger_value of TRUE, the wait operation will block suspending the calling thread.
The wait operation takes a timeout argument that specifies the maximum duration for the wait. If this duration is exceeded and none of the attached Condition objects is true, a TimeoutError will be thrown.
It is not allowed for more than one application thread to be waiting on the same WaitSet. If the wait operation is invoked on a WaitSet that already has a thread blocking on it, the operation will immediately raise a PreconditionNotMetError exception.
The result of the wait operation is the list of all the attached Conditions that have a trigger_value of TRUE (i.e., the Conditions that unblocked the wait).
- Parameters
timeout – The maximum amount of time for which the wait should block while waiting for a Condition to be triggered.
- Throws
dds::core::NullReferenceError – The WaitSet was not properly created and references to dds::core::null.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
dds::core::TimeoutError – The timeout has elapsed without any of the attached conditions becoming TRUE.
dds::core::PreconditionNotMetError – When multiple thread try to invoke the function concurrently.
- Returns
ConditionSeq A vector containing the triggered Conditions
-
const ConditionSeq wait()¶
This operation allows an application thread to wait for the occurrence of at least one of the conditions that is attached to the WaitSet.
This operation allows an application thread to wait for the occurrence of certain Conditions. If none of the Conditions attached to the WaitSet have a trigger_value of TRUE, the wait operation will block suspending the calling thread.
It is not allowed for more than one application thread to be waiting on the same WaitSet. If the wait operation is invoked on a WaitSet that already has a thread blocking on it, the operation will immediately raise a PreconditionNotMetError exception.
The result of the wait operation is the list of all the attached Conditions that have a trigger_value of TRUE (i.e., the Conditions that unblocked the wait).
- Throws
dds::core::NullReferenceError – The WaitSet was not properly created and references to dds::core::null.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
dds::core::PreconditionNotMetError – When multiple thread try to invoke the function concurrently.
- Returns
ConditionSeq A vector containing the triggered Conditions
-
ConditionSeq &wait(ConditionSeq &triggered, const dds::core::Duration &timeout)¶
This operation allows an application thread to wait for the occurrence of at least one of the conditions that is attached to the WaitSet.
This operation allows an application thread to wait for the occurrence of certain Conditions. If none of the Conditions attached to the WaitSet have a trigger_value of TRUE, the wait operation will block suspending the calling thread.
The wait operation takes a timeout argument that specifies the maximum duration for the wait. If this duration is exceeded and none of the attached Condition objects is true, a TimeoutError will be thrown.
It is not allowed for more than one application thread to be waiting on the same WaitSet. If the wait operation is invoked on a WaitSet that already has a thread blocking on it, the operation will immediately raise a PreconditionNotMetError exception.
The result of the wait operation is the list of all the attached Conditions that have a trigger_value of TRUE (i.e., the Conditions that unblocked the wait).
- Parameters
triggered – A ConditionSeq in which to put Conditions that were triggered during the wait.
timeout – The maximum amount of time for which the wait should block while waiting for a Condition to be triggered.
- Throws
dds::core::NullReferenceError – The WaitSet was not properly created and references to dds::core::null.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
dds::core::TimeoutError – The timeout has elapsed without any of the attached conditions becoming TRUE.
dds::core::PreconditionNotMetError – When multiple thread try to invoke the function concurrently.
- Returns
ConditionSeq A vector containing the triggered Conditions
-
ConditionSeq &wait(ConditionSeq &triggered)¶
This operation allows an application thread to wait for the occurrence of at least one of the conditions that is attached to the WaitSet.
This operation allows an application thread to wait for the occurrence of certain Conditions. If none of the Conditions attached to the WaitSet have a trigger_value of TRUE, the wait operation will block suspending the calling thread.
It is not allowed for more than one application thread to be waiting on the same WaitSet. If the wait operation is invoked on a WaitSet that already has a thread blocking on it, the operation will immediately raise a PreconditionNotMetError exception.
The result of the wait operation is the list of all the attached Conditions that have a trigger_value of TRUE (i.e., the Conditions that unblocked the wait).
- Parameters
triggered – A ConditionSeq in which to put Conditions that were triggered during the wait.
- Throws
dds::core::NullReferenceError – The WaitSet was not properly created and references to dds::core::null.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
dds::core::PreconditionNotMetError – When multiple thread try to invoke the function concurrently.
- Returns
ConditionSeq A vector containing the triggered Conditions
-
void dispatch()¶
Waits for at least one of the attached Conditions to trigger and then dispatches the functor associated with the Condition.
- Throws
dds::core::NullReferenceError – The WaitSet was not properly created and references to dds::core::null.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
dds::core::PreconditionNotMetError – When multiple thread try to invoke the function concurrently.
-
void dispatch(const dds::core::Duration &timeout)¶
Waits for at least one of the attached Conditions to trigger and then dispatches the functor associated with the Condition, or, times out and throws a TimeoutError.
- Parameters
timeout – The maximum amount of time for which the dispatch should block while waiting for a Condition to be triggered.
- Throws
dds::core::NullReferenceError – The WaitSet was not properly created and references to dds::core::null.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
dds::core::TimeoutError – The timeout has elapsed without any of the attached conditions becoming TRUE.
dds::core::PreconditionNotMetError – When multiple thread try to invoke the function concurrently.
-
TWaitSet &operator+=(const dds::core::cond::Condition &cond)¶
This operation attaches a Condition to the WaitSet.
Attaches a Condition to the WaitSet. It is possible to attach a Condition on a WaitSet that is currently being waited upon (via the wait operation). In this case, if the Condition has a trigger_value of TRUE, then attaching the Condition will unblock the WaitSet. Adding a Condition that is already attached to the WaitSet has no effect.
- Parameters
cond – The Condition to be attached to this WaitSet.
- Throws
dds::core::NullReferenceError – The WaitSet was not properly created and references to dds::core::null.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
- Returns
WaitSet The WaitSet itself so that attaching Conditions can be chained.
-
TWaitSet &operator-=(const dds::core::cond::Condition &cond)¶
This operation detaches a Condition to the WaitSet.
Detaches a Condition from the WaitSet. If the Condition was not attached to the WaitSet, the operation will return false.
- Parameters
cond – The Condition to detach from this WaitSet
- Throws
dds::core::NullReferenceError – The WaitSet was not properly created and references to dds::core::null.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
- Returns
bool True if the Condition was found and detached, False if the Condition was not part of the WaitSet.
-
TWaitSet &attach_condition(const dds::core::cond::Condition &cond)¶
This operation attaches a Condition to the WaitSet.
Attaches a Condition to the WaitSet. It is possible to attach a Condition on a WaitSet that is currently being waited upon (via the wait operation). In this case, if the Condition has a trigger_value of TRUE, then attaching the Condition will unblock the WaitSet. Adding a Condition that is already attached to the WaitSet has no effect.
- Parameters
cond – The Condition to be attached to this WaitSet.
- Throws
dds::core::NullReferenceError – The WaitSet was not properly created and references to dds::core::null.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
- Returns
WaitSet The WaitSet itself so that attaching Conditions can be chained.
-
bool detach_condition(const dds::core::cond::Condition &cond)¶
This operation detaches a Condition to the WaitSet.
Detaches a Condition from the WaitSet. If the Condition was not attached to the WaitSet, the operation will return false.
- Parameters
cond – The Condition to detach from this WaitSet
- Throws
dds::core::NullReferenceError – The WaitSet was not properly created and references to dds::core::null.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
- Returns
bool True if the Condition was found and detached, False if the Condition was not part of the WaitSet.
-
const ConditionSeq conditions() const¶
This operation retrieves the list of attached Conditions.
The resulting sequence will either be an empty sequence, meaning there were no conditions attached, or will contain a list of ReadCondition, QueryCondition, StatusCondition and GuardCondition.
- Throws
dds::core::NullReferenceError – The WaitSet was not properly created and references to dds::core::null.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
- Returns
ConditionSeq The list of attached Conditions.
-
ConditionSeq &conditions(ConditionSeq &conds) const¶
This operation retrieves the list of attached Conditions.
The resulting sequence will either be an empty sequence, meaning there were no conditions attached, or will contain a list of ReadCondition, QueryCondition, StatusCondition and GuardCondition.
- Parameters
conds – A ConditionSeq in which to put the attached Conditions.
- Throws
dds::core::NullReferenceError – The WaitSet was not properly created and references to dds::core::null.
dds::core::OutOfResourcesError – The Data Distribution Service ran out of resources to complete this operation.
- Returns
ConditionSeq The list of attached Conditions.
-
TWaitSet()¶
-
namespace detail¶
Typedefs
-
typedef dds::core::cond::TCondition<org::eclipse::cyclonedds::core::cond::ConditionDelegate> Condition¶
-
typedef dds::core::cond::TGuardCondition<org::eclipse::cyclonedds::core::cond::GuardConditionDelegate> GuardCondition¶
-
typedef dds::core::cond::TStatusCondition<org::eclipse::cyclonedds::core::cond::StatusConditionDelegate> StatusCondition¶
-
typedef dds::core::cond::TCondition<org::eclipse::cyclonedds::core::cond::ConditionDelegate> Condition¶
-
typedef dds::core::cond::detail::GuardCondition GuardCondition¶
-
namespace detail¶
Typedefs
-
typedef dds::core::TInstanceHandle<org::eclipse::cyclonedds::core::InstanceHandleDelegate> InstanceHandle¶
-
class BytesTopicType¶
-
class StringTopicType¶
-
class KeyedBytesTopicType¶
-
class KeyedStringTopicType¶
-
typedef dds::core::TInstanceHandle<org::eclipse::cyclonedds::core::InstanceHandleDelegate> InstanceHandle¶
-
namespace policy¶
Typedefs
-
typedef dds::core::policy::detail::DestinationOrder DestinationOrder¶
-
typedef dds::core::policy::detail::Durability Durability¶
-
typedef dds::core::policy::detail::EntityFactory EntityFactory¶
-
typedef dds::core::policy::detail::LatencyBudget LatencyBudget¶
-
typedef dds::core::policy::detail::Liveliness Liveliness¶
-
typedef dds::core::policy::detail::Presentation Presentation¶
-
typedef ::dds::core::policy::detail::QosPolicyCount QosPolicyCount¶
-
typedef std::vector<QosPolicyCount> QosPolicyCountSeq¶
-
typedef uint32_t QosPolicyId¶
-
typedef dds::core::policy::detail::ReaderDataLifecycle ReaderDataLifecycle¶
-
typedef dds::core::policy::detail::Reliability Reliability¶
-
typedef dds::core::policy::detail::ResourceLimits ResourceLimits¶
-
typedef dds::core::policy::detail::TimeBasedFilter TimeBasedFilter¶
-
typedef dds::core::policy::detail::TransportPriority TransportPriority¶
-
typedef dds::core::policy::detail::PSMXInstances PSMXInstances¶
-
typedef dds::core::policy::detail::WriterDataLifecycle WriterDataLifecycle¶
-
typedef dds::core::policy::detail::WriterBatching WriterBatching¶
-
typedef dds::core::safe_enum<OwnershipKind_def> OwnershipKind¶
-
typedef dds::core::safe_enum<DataRepresentationId_def> DataRepresentationId¶
-
typedef std::vector<DataRepresentationId> DataRepresentationIdSeq¶
-
typedef dds::core::safe_enum<DurabilityKind_def> DurabilityKind¶
-
typedef dds::core::safe_enum<PresentationAccessScopeKind_def> PresentationAccessScopeKind¶
-
typedef dds::core::safe_enum<ReliabilityKind_def> ReliabilityKind¶
-
typedef dds::core::safe_enum<DestinationOrderKind_def> DestinationOrderKind¶
-
typedef dds::core::safe_enum<HistoryKind_def> HistoryKind¶
-
typedef dds::core::safe_enum<LivelinessKind_def> LivelinessKind¶
-
typedef dds::core::safe_enum<TypeConsistencyKind_def> TypeConsistencyKind¶
-
template<typename Policy>
class policy_id¶
-
template<typename Policy>
class policy_name¶
-
template<>
class policy_id<UserData>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 1¶
-
static const dds::core::policy::QosPolicyId value = 1¶
-
template<>
class policy_id<Durability>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 2¶
-
static const dds::core::policy::QosPolicyId value = 2¶
-
template<>
class policy_name<Durability>¶ Public Static Functions
-
static const std::string &name()¶
-
static const std::string &name()¶
-
template<>
class policy_id<Presentation>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 3¶
-
static const dds::core::policy::QosPolicyId value = 3¶
-
template<>
class policy_name<Presentation>¶ Public Static Functions
-
static const std::string &name()¶
-
static const std::string &name()¶
-
template<>
class policy_id<Deadline>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 4¶
-
static const dds::core::policy::QosPolicyId value = 4¶
-
template<>
class policy_id<LatencyBudget>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 5¶
-
static const dds::core::policy::QosPolicyId value = 5¶
-
template<>
class policy_name<LatencyBudget>¶ Public Static Functions
-
static const std::string &name()¶
-
static const std::string &name()¶
-
template<>
class policy_id<Ownership>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 6¶
-
static const dds::core::policy::QosPolicyId value = 6¶
-
template<>
class policy_id<Liveliness>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 8¶
-
static const dds::core::policy::QosPolicyId value = 8¶
-
template<>
class policy_name<Liveliness>¶ Public Static Functions
-
static const std::string &name()¶
-
static const std::string &name()¶
-
template<>
class policy_id<TimeBasedFilter>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 9¶
-
static const dds::core::policy::QosPolicyId value = 9¶
-
template<>
class policy_name<TimeBasedFilter>¶ Public Static Functions
-
static const std::string &name()¶
-
static const std::string &name()¶
-
template<>
class policy_id<Partition>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 10¶
-
static const dds::core::policy::QosPolicyId value = 10¶
-
template<>
class policy_id<Reliability>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 11¶
-
static const dds::core::policy::QosPolicyId value = 11¶
-
template<>
class policy_name<Reliability>¶ Public Static Functions
-
static const std::string &name()¶
-
static const std::string &name()¶
-
template<>
class policy_id<DestinationOrder>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 12¶
-
static const dds::core::policy::QosPolicyId value = 12¶
-
template<>
class policy_name<DestinationOrder>¶ Public Static Functions
-
static const std::string &name()¶
-
static const std::string &name()¶
-
template<>
class policy_id<History>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 13¶
-
static const dds::core::policy::QosPolicyId value = 13¶
-
template<>
class policy_id<ResourceLimits>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 14¶
-
static const dds::core::policy::QosPolicyId value = 14¶
-
template<>
class policy_name<ResourceLimits>¶ Public Static Functions
-
static const std::string &name()¶
-
static const std::string &name()¶
-
template<>
class policy_id<EntityFactory>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 15¶
-
static const dds::core::policy::QosPolicyId value = 15¶
-
template<>
class policy_name<EntityFactory>¶ Public Static Functions
-
static const std::string &name()¶
-
static const std::string &name()¶
-
template<>
class policy_id<WriterDataLifecycle>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 16¶
-
static const dds::core::policy::QosPolicyId value = 16¶
-
template<>
class policy_name<WriterDataLifecycle>¶ Public Static Functions
-
static const std::string &name()¶
-
static const std::string &name()¶
-
template<>
class policy_id<ReaderDataLifecycle>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 17¶
-
static const dds::core::policy::QosPolicyId value = 17¶
-
template<>
class policy_name<ReaderDataLifecycle>¶ Public Static Functions
-
static const std::string &name()¶
-
static const std::string &name()¶
-
template<>
class policy_id<TopicData>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 18¶
-
static const dds::core::policy::QosPolicyId value = 18¶
-
template<>
class policy_id<GroupData>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 19¶
-
static const dds::core::policy::QosPolicyId value = 19¶
-
template<>
class policy_id<TransportPriority>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 20¶
-
static const dds::core::policy::QosPolicyId value = 20¶
-
template<>
class policy_name<TransportPriority>¶ Public Static Functions
-
static const std::string &name()¶
-
static const std::string &name()¶
-
template<>
class policy_id<Lifespan>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 21¶
-
static const dds::core::policy::QosPolicyId value = 21¶
-
template<>
class policy_id<WriterBatching>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 25¶
-
static const dds::core::policy::QosPolicyId value = 25¶
-
template<>
class policy_name<WriterBatching>¶ Public Static Functions
-
static const std::string &name()¶
-
static const std::string &name()¶
-
template<>
class policy_id<PSMXInstances>¶ Public Static Attributes
-
static const dds::core::policy::QosPolicyId value = 34¶
-
static const dds::core::policy::QosPolicyId value = 34¶
-
template<>
class policy_name<PSMXInstances>¶ Public Static Functions
-
static const std::string &name()¶
-
static const std::string &name()¶
-
struct OwnershipKind_def¶
-
struct DataRepresentationId_def¶
-
struct DurabilityKind_def¶
Public Types
-
enum Type¶
Values:
-
enumerator VOLATILE¶
The samples are not available to late-joining DataReaders. In other words, only DataReaders, which were present at the time of the writing and have subscribed to this Topic, will receive the sample. When a DataReader subscribes afterwards (late-joining), it will only be able to read the next written sample. This setting is typically used for data, which is updated quickly.
-
enumerator TRANSIENT_LOCAL¶
Currently behaves identically to the TRANSIENT_DURABILITY_QOS, except for its RxO properties. The desired behaviour of TRANSIENT_LOCAL_DURABILITY_QOS can be achieved from the TRANSIENT_DURABILITY_QOS with the default (TRUE) setting of the autodispose_unregistered_instances flag on the DataWriter and the service_cleanup_delay set to 0 on the durability service. This is because for TRANSIENT_LOCAL, the data should only remain available for late-joining readers during the lifetime of its source writer, so it is not required to survive after its source writer has been deleted. Since the deletion of a writer implicitly unregisters all its instances, an autodispose_unregistered_instances value of TRUE will also dispose the affected data from the durability store, and thus prevent it from remaining available to late joining readers.
-
enumerator VOLATILE¶
-
enum Type¶
-
struct PresentationAccessScopeKind_def¶
-
struct ReliabilityKind_def¶
Public Types
-
enum Type¶
Values:
-
enumerator BEST_EFFORT¶
The Data Distribution Service will only attempt to deliver the data; no arrival-checks are being performed and any lost data is not re-transmitted (non-reliable). Presumably new values for the samples are generated often enough by the application so that it is not necessary to resent or acknowledge any samples.
-
enumerator RELIABLE¶
The Data Distribution Service will attempt to deliver all samples in the DataWriters history; arrival-checks are performed and data may get re-transmitted in case of lost data. In the steady-state (no modifications communicated via the DataWriter) the Data Distribution Service guarantees that all samples in the DataWriter history will eventually be delivered to the all DataReader objects. Outside the steady-state the HistoryQosPolicy and ResourceLimitsQosPolicy determine how samples become part of the history and whether samples can be discarded from it. In this case also the max_blocking_time must be set.
-
enumerator BEST_EFFORT¶
-
enum Type¶
-
struct DestinationOrderKind_def¶
Public Types
-
enum Type¶
Values:
-
enumerator BY_RECEPTION_TIMESTAMP¶
The order is based on the timestamp, at the moment the sample was received by the DataReader.
-
enumerator BY_SOURCE_TIMESTAMP¶
The order is based on the timestamp, which was set by the DataWriter. This means that the system needs some time synchronization.
-
enumerator BY_RECEPTION_TIMESTAMP¶
-
enum Type¶
-
struct HistoryKind_def¶
Public Types
-
enum Type¶
Values:
-
enumerator KEEP_LAST¶
The Data Distribution Service will only attempt to keep the latest values of the instance and discard the older ones. The attribute “depth” determines how many samples in history will be stored. In other words, only the most recent samples in history are stored. On the publishing side, the Data Distribution Service will only keep the most recent “depth” samples of each instance of data (identified by its key) managed by the DataWriter. On the subscribing side, the DataReader will only keep the most recent “depth” samples received for each instance (identified by its key) until the application “takes” them via the DataReader::take operation. KEEP_LAST_HISTORY_QOS - is the default kind. The default value of depth is 1, indicating that only the most recent value should be delivered. If a depth other than 1 is specified, it should be compatible with the settings of the ResourcelimitsQosPolicy max_samples_per_instance. For these two QosPolicy settings to be compatible, they must verify that depth <= max_samples_per_instance, otherwise a RETCODE_INCONSISTENT_POLICY is generated on relevant operations.
-
enumerator KEEP_ALL¶
All samples are stored, provided, the resources are available. On the publishing side, the Data Distribution Service will attempt to keep all samples (representing each value written) of each instance of data (identified by its key) managed by the DataWriter until they can be delivered to all subscribers. On the subscribing side, the Data Distribution Service will attempt to keep all samples of each instance of data (identified by its key) managed by the DataReader. These samples are kept until the application “takes” them from the Data Distribution Service via the DataReader::take operation. The setting of depth has no effect. Its implied value is LENGTH_UNLIMITED. The resources that the Data Distribution Service can use to keep this history are limited by the settings of the ResourceLimitsQosPolicy. If the limit is reached, the behaviour of the Data Distribution Service will depend on the ReliabilityQosPolicy. If the ReliabilityQosPolicy is BEST_EFFORT_RELIABILITY_QOS, the old values are discarded. If ReliabilityQosPolicy is RELIABLE_RELIABILITY_QOS, the Data Distribution Service will block the DataWriter until it can deliver the necessary old values to all subscribers.
-
enumerator KEEP_LAST¶
-
enum Type¶
-
struct LivelinessKind_def¶
Public Types
-
enum Type¶
Values:
-
enumerator AUTOMATIC¶
The Data Distribution Service will take care of reporting the Liveliness automatically with a rate determined by the lease_duration.
-
enumerator MANUAL_BY_PARTICIPANT¶
The application must take care of reporting the liveliness before the lease_duration expires. If an Entity reports its liveliness, all Entities within the same DomainParticipant that have their liveliness kind set to MANUAL_BY_PARTICIPANT_LIVELINESS_QOS, can be considered alive by the Data Distribution Service. Liveliness can reported explicitly by calling the operation assert_liveliness on the DomainParticipant or implicitly by writing some data.
-
enumerator MANUAL_BY_TOPIC¶
The application must take care of reporting the liveliness before the lease_duration expires. This can explicitly be done by calling the operation assert_liveliness on the DataWriter or implicitly by writing some data.
-
enumerator AUTOMATIC¶
-
enum Type¶
-
struct TypeConsistencyKind_def¶
-
template<typename D>
class TUserData : public dds::core::Value<D>¶ - #include <TCorePolicy.hpp>
Public Functions
-
TUserData()¶
Creates a UserData QoS instance with an empty UserData
-
explicit TUserData(const dds::core::ByteSeq &sequence)¶
Creates a UserData QoS instance
- Parameters
sequence – the sequence of octets
-
TUserData(const uint8_t *value_begin, const uint8_t *value_end)¶
Creates a UserData QoS instance
- Parameters
value_begin – a pointer to the beginning of a sequence of octets
value_end – a pointer to the end of a sequence of octets
-
TUserData(const TUserData &other)¶
Copies a UserData QoS instance
- Parameters
other – the UserData QoS instance to copy
-
TUserData &operator=(const TUserData &other) = default¶
Copies a UserData QoS instance
- Parameters
other – the UserData QoS instance to copy
- Returns
Reference to the Userdata QoS instance that was copied to
-
TUserData &value(const dds::core::ByteSeq &sequence)¶
Sets the sequence
- Parameters
sequence – a sequence of octets
-
template<typename OCTET_ITER>
TUserData &value(OCTET_ITER begin, OCTET_ITER end)¶ Sets the sequence
- Parameters
begin – an iterator pointing to the beginning of a sequence of octets
end – an iterator pointing to the end of a sequence of octets
-
const uint8_t *begin() const¶
Gets a pointer to the first octet in the sequence
- Returns
a pointer to the first octet in the sequence
-
const uint8_t *end() const¶
Gets a pointer to the last octet in the sequence
- Returns
a pointer to the first octet in the sequence
-
template<typename OCTET_ITER>
TUserData<D> &value(OCTET_ITER begin, OCTET_ITER end)¶
-
TUserData()¶
-
template<typename D>
class TGroupData : public dds::core::Value<D>¶ - #include <TCorePolicy.hpp>
Public Functions
-
TGroupData()¶
Creates a GroupData QoS instance
-
explicit TGroupData(const dds::core::ByteSeq &sequence)¶
Creates a GroupData QoS instance
- Parameters
sequence – the sequence of octets representing the GroupData
-
TGroupData(const TGroupData &other)¶
Copies a GroupData QoS instance
- Parameters
other – the GroupData QoS instance to copy
-
TGroupData &operator=(const TGroupData &other) = default¶
Copies a GroupData QoS instance
- Parameters
other – the GroupData QoS instance to copy
- Returns
Reference to the GroupData QoS instance that was copied to
-
TGroupData(const uint8_t *value_begin, const uint8_t *value_end)¶
Creates a GroupData QoS instance
- Parameters
value_begin – a pointer to the beginning of a sequence of octets
value_end – a pointer to the end of a sequence of octets
-
TGroupData &value(const dds::core::ByteSeq &sequence)¶
Set the sequence
- Parameters
sequence – a sequence of octets
-
template<typename OCTET_ITER>
TGroupData &value(OCTET_ITER begin, OCTET_ITER end)¶ Set the sequence
- Parameters
begin – an iterator pointing to the beginning of a sequence of octets
end – an iterator pointing to the end of a sequence of octets
-
const uint8_t *begin() const¶
Gets a pointer to the first octet in the sequence
- Returns
a pointer to the first octet in the sequence
-
const uint8_t *end() const¶
Gets a pointer to the last octet in the sequence
- Returns
a pointer to the last octet in the sequence
-
template<typename OCTET_ITER>
TGroupData<D> &value(OCTET_ITER begin, OCTET_ITER end)¶
-
TGroupData()¶
-
template<typename D>
class TTopicData : public dds::core::Value<D>¶ - #include <TCorePolicy.hpp>
Public Functions
-
TTopicData()¶
Creates a TopicData QoS instance
-
explicit TTopicData(const dds::core::ByteSeq &sequence)¶
Creates a TopicData QoS instance
- Parameters
sequence – the sequence of octets representing the TopicData
-
TTopicData(const TTopicData &other)¶
Copies a TopicData QoS instance
- Parameters
other – the TopicData QoS instance to copy
-
TTopicData(const uint8_t *value_begin, const uint8_t *value_end)¶
Creates a TopicData QoS instance
- Parameters
value_begin – a pointer to the beginning of a sequence of octets
value_end – a pointer to the end of a sequence of octets
-
TTopicData &operator=(const TTopicData &other) = default¶
Copies a TopicData QoS instance
- Parameters
other – the TopicData QoS instance to copy
- Returns
Reference to the TopicData QoS instance that was copied to
-
TTopicData &value(const dds::core::ByteSeq &sequence)¶
Set the sequence
- Parameters
sequence – a sequence of octets
-
template<typename OCTET_ITER>
TTopicData &value(OCTET_ITER begin, OCTET_ITER end)¶ Set the sequence
- Parameters
begin – an iterator pointing to the beginning of a sequence of octets
end – an iterator pointing to the end of a sequence of octets
-
const uint8_t *begin() const¶
Gets a pointer to the first octet in the sequence
- Returns
a pointer to the first octet in the sequence
-
const uint8_t *end() const¶
Gets a pointer to the last octet in the sequence
- Returns
a pointer to the last octet in the sequence
-
template<typename OCTET_ITER>
TTopicData<D> &value(OCTET_ITER begin, OCTET_ITER end)¶
-
TTopicData()¶
-
template<typename D>
class TEntityFactory : public dds::core::Value<D>¶ - #include <TCorePolicy.hpp>
Public Functions
-
explicit TEntityFactory(bool autoenable_created_entities = true)¶
Creates an EntityFactory QoS instance
- Parameters
autoenable_created_entities – boolean indicating whether created Entities should be automatically enabled
-
TEntityFactory(const TEntityFactory &other)¶
Copies an EntityFactory QoS instance
- Parameters
other – the EntityFactory QoS instance to copy
-
TEntityFactory &operator=(const TEntityFactory &other) = default¶
Copies an EntityFactory QoS instance
- Parameters
other – the EntityFactory QoS instance to copy
- Returns
Reference to the EntityFactory QoS instance that was copied to
-
TEntityFactory &autoenable_created_entities(bool autoenable_created_entities)¶
Sets a boolean indicating whether created Entities should be automatically enabled
- Parameters
autoenable_created_entities – boolean indicating whether created Entities should be automatically enabled
-
bool autoenable_created_entities() const¶
Gets a boolean indicating whether Entities should be automatically enabled
- Returns
boolean indicating whether created Entities should be automatically enabled
Public Static Functions
-
static TEntityFactory AutoEnable()¶
- Returns
an EntityFactory QoS instance with autoenable_created_entities set to true
-
static TEntityFactory ManuallyEnable()¶
- Returns
an EntityFactory QoS instance with autoenable_created_entities set to false
-
explicit TEntityFactory(bool autoenable_created_entities = true)¶
-
template<typename D>
class TTransportPriority : public dds::core::Value<D>¶ - #include <TCorePolicy.hpp>
Public Functions
-
explicit TTransportPriority(int32_t priority = 0)¶
Creates a TransportPriority QoS instance
- Parameters
priority – the priority value
-
TTransportPriority(const TTransportPriority &other)¶
Copies a TransportPriority QoS instance
- Parameters
other – the TransportPriority QoS instance to copy
-
TTransportPriority &operator=(const TTransportPriority &other) = default¶
Copies a TransportPriority QoS instance
- Parameters
other – the TransportPriority QoS instance to copy
- Returns
Reference to the TransportPriority QoS instance that was copied to
-
TTransportPriority &value(int32_t priority)¶
Sets the priority value
- Parameters
priority – the priority value
-
int32_t value() const¶
Gets the priority value
- Returns
the priority value
-
explicit TTransportPriority(int32_t priority = 0)¶
-
template<typename D>
class TLifespan : public dds::core::Value<D>¶ - #include <TCorePolicy.hpp>
Public Functions
-
explicit TLifespan(const dds::core::Duration &duration = dds::core::Duration::infinite())¶
Creates a Lifespan QoS instance
- Parameters
duration – Lifespan expiration duration
-
TLifespan(const TLifespan &other)¶
Copies a Lifespan QoS instance
- Parameters
other – the Lifespan QoS instance to copy
-
TLifespan &operator=(const TLifespan &other) = default¶
Copies a Lifespan QoS instance
- Parameters
other – the Lifespan QoS instance to copy
- Returns
Reference to the Lifespan QoS instance that was copied to
-
explicit TLifespan(const dds::core::Duration &duration = dds::core::Duration::infinite())¶
-
template<typename D>
class TDeadline : public dds::core::Value<D>¶ - #include <TCorePolicy.hpp>
Public Functions
-
explicit TDeadline(const dds::core::Duration &period = dds::core::Duration::infinite())¶
Creates a Deadline QoS instance
- Parameters
period – deadline period
-
TDeadline(const TDeadline &other)¶
Copies a Deadline QoS instance
- Parameters
other – the Deadline QoS instance to copy
-
TDeadline &operator=(const TDeadline &other) = default¶
Copies a Deadline QoS instance
- Parameters
other – the Deadline QoS instance to copy
- Returns
reference to the Deadline QoS instance that was copied to
-
explicit TDeadline(const dds::core::Duration &period = dds::core::Duration::infinite())¶
-
template<typename D>
class TLatencyBudget : public dds::core::Value<D>¶ - #include <TCorePolicy.hpp>
Public Functions
-
explicit TLatencyBudget(const dds::core::Duration &duration = dds::core::Duration::zero())¶
Creates a LatencyBudget QoS instance
- Parameters
duration – duration
-
TLatencyBudget(const TLatencyBudget &other)¶
Copies a LatencyBudget QoS instance
- Parameters
other – the LatencyBudget QoS instance to copy
-
TLatencyBudget &operator=(const TLatencyBudget &other) = default¶
Copies a LatencyBudget QoS instance
- Parameters
other – the LatencyBudget QoS instance to copy
- Returns
reference to the LatencyBudget QoS instance that was copied to
-
TLatencyBudget &duration(const dds::core::Duration &duration)¶
Sets the duration
- Parameters
duration – duration
-
explicit TLatencyBudget(const dds::core::Duration &duration = dds::core::Duration::zero())¶
-
template<typename D>
class TTimeBasedFilter : public dds::core::Value<D>¶ - #include <TCorePolicy.hpp>
Public Functions
-
explicit TTimeBasedFilter(const dds::core::Duration &period = dds::core::Duration::zero())¶
Creates a TimeBasedFilter QoS instance
- Parameters
period – minimum separation period
-
TTimeBasedFilter(const TTimeBasedFilter &other)¶
Copies a TimeBasedFilter QoS instance
- Parameters
other – the TimeBasedFilter QoS instance to copy
-
TTimeBasedFilter &operator=(const TTimeBasedFilter &other) = default¶
Copies a TimeBasedFilter QoS instance
- Parameters
other – the TimeBasedFilter QoS instance to copy
- Returns
reference to the TimeBasedFilter QoS instance that was copied to
-
TTimeBasedFilter &minimum_separation(const dds::core::Duration &period)¶
Sets the minimum separation period
- Parameters
period – minimum separation period
-
explicit TTimeBasedFilter(const dds::core::Duration &period = dds::core::Duration::zero())¶
-
template<typename D>
class TPartition : public dds::core::Value<D>¶ - #include <TCorePolicy.hpp>
Public Functions
-
explicit TPartition(const std::string &name = "")¶
Creates a Partition QoS instance
- Parameters
name – partition name
-
explicit TPartition(const dds::core::StringSeq &names)¶
Creates a Partition QoS instance
- Parameters
names – a sequence containing multiple partition names
-
TPartition(const TPartition &other)¶
Copies a Partition QoS instance
- Parameters
other – the Partition QoS instance to copy
-
TPartition &operator=(const TPartition &other) = default¶
Copies a Partition QoS instance
- Parameters
other – the Partition QoS instance to copy
- Returns
reference to the Partition QoS instance that was copied to
-
TPartition &name(const std::string &name)¶
Sets the partition name
- Parameters
name – the partition name
-
TPartition &name(const dds::core::StringSeq &names)¶
Sets multiple partition names
- Parameters
names – a sequence containing multiple partition names
-
explicit TPartition(const std::string &name = "")¶
-
template<typename D>
class TWriterDataLifecycle : public dds::core::Value<D>¶ - #include <TCorePolicy.hpp>
Public Functions
-
explicit TWriterDataLifecycle(bool autodispose_unregistered_instances = true)¶
Creates a WriterDataLifecycle QoS instance
- Parameters
autodispose_unregistered_instances – a boolean indicating if unregistered instances should be autodisposed
-
TWriterDataLifecycle(const TWriterDataLifecycle &other)¶
Copies a WriterDataLifecycle QoS instance
- Parameters
other – the WriterDataLifecycle QoS instance to copy
-
TWriterDataLifecycle &operator=(const TWriterDataLifecycle &other) = default¶
Copies a WriterDataLifecycle QoS instance
- Parameters
other – the WriterDataLifecycle QoS instance to copy
- Returns
reference to the WriterDataLifecycle QoS instance that was copied to
-
bool autodispose_unregistered_instances() const¶
Gets a boolean indicating if unregistered instances should be autodisposed
- Returns
a boolean indicating if unregistered instances should be autodisposed
-
TWriterDataLifecycle &autodispose_unregistered_instances(bool autodispose_unregistered_instances)¶
Sets a boolean indicating if unregistered instances should be autodisposed
- Parameters
autodispose_unregistered_instances – a boolean indicating if unregistered instances should be autodisposed
Public Static Functions
-
static TWriterDataLifecycle AutoDisposeUnregisteredInstances()¶
- Returns
a WriterDataLifecycle QoS instance with autodispose_unregistered_instances set to true
-
static TWriterDataLifecycle ManuallyDisposeUnregisteredInstances()¶
- Returns
a WriterDataLifecycle QoS instance with autodispose_unregistered_instances set to false
-
explicit TWriterDataLifecycle(bool autodispose_unregistered_instances = true)¶
-
template<typename D>
class TWriterBatching : public dds::core::Value<D>¶ Public Functions
-
explicit TWriterBatching(bool batch_updates = false)¶
Creates a WriterBatching QoS instance
- Parameters
batch_updates – a boolean indicating if updates should be batched before being explicitly flushed
-
TWriterBatching(const TWriterBatching &other)¶
Copies a WriterBatching QoS instance
- Parameters
other – the WriterBatching QoS instance to copy
-
TWriterBatching &operator=(const TWriterBatching &other) = default¶
Copies a WriterBatching QoS instance
- Parameters
other – the WriterBatching QoS instance to copy
- Returns
reference to the WriterBatching QoS instance that was copied to
-
bool batch_updates() const¶
Gets a boolean indicating if updates should be batched
- Returns
a boolean indicating if updates should be batched
-
TWriterBatching &batch_updates(bool batch_updates)¶
Sets a boolean indicating if updates should be batched
- Parameters
batch_updates – a boolean indicating if updates should be batched
Public Static Functions
-
static TWriterBatching BatchUpdates()¶
- Returns
a WriterBatching QoS instance with batch_updates set to true
-
static TWriterBatching DoNotBatchUpdates()¶
- Returns
a WriterBatching QoS instance with batch_updates set to false
-
explicit TWriterBatching(bool batch_updates = false)¶
-
template<typename D>
class TReaderDataLifecycle : public dds::core::Value<D>¶ - #include <TCorePolicy.hpp>
Public Functions
-
TReaderDataLifecycle(const dds::core::Duration &autopurge_nowriter_samples_delay = dds::core::Duration::infinite(), const dds::core::Duration &autopurge_disposed_samples_delay = dds::core::Duration::infinite())¶
Creates a ReaderDataLifecycle QoS instance
- Parameters
autopurge_nowriter_samples_delay – the autopurge nowriter samples delay
autopurge_disposed_samples_delay – the autopurge disposed samples delay
-
TReaderDataLifecycle(const TReaderDataLifecycle &other)¶
Copies a ReaderDataLifecycle QoS instance
- Parameters
other – the ReaderDataLifecycle QoS instance to copy
-
TReaderDataLifecycle &operator=(const TReaderDataLifecycle &other) = default¶
Copies a ReaderDataLifecycle QoS instance
- Parameters
other – the ReaderDataLifecycle QoS instance to copy
- Returns
reference to the ReaderDataLifecycle QoS that was copied to
-
const dds::core::Duration autopurge_nowriter_samples_delay() const¶
Gets the autopurge nowriter samples delay
- Returns
the autopurge nowriter samples delay
-
TReaderDataLifecycle &autopurge_nowriter_samples_delay(const dds::core::Duration &autopurge_nowriter_samples_delay)¶
Sets the autopurge nowriter samples delay
- Parameters
autopurge_nowriter_samples_delay – the autopurge nowriter samples delay
-
const dds::core::Duration autopurge_disposed_samples_delay() const¶
Gets the autopurge_disposed_samples_delay
- Returns
the autopurge disposed samples delay
-
TReaderDataLifecycle &autopurge_disposed_samples_delay(const dds::core::Duration &autopurge_disposed_samples_delay)¶
Sets the autopurge_disposed_samples_delay
- Returns
the autopurge disposed samples delay
Public Static Functions
-
static TReaderDataLifecycle NoAutoPurgeDisposedSamples()¶
- Returns
a ReaderDataLifecycle QoS instance which will not autopurge disposed samples
-
static TReaderDataLifecycle AutoPurgeDisposedSamples(const dds::core::Duration &autopurge_disposed_samples_delay)¶
- Parameters
autopurge_disposed_samples_delay – the autopurge disposed samples delay
- Returns
a ReaderDataLifecycle QoS instance with autopurge_disposed_samples_delay set to a specified value
-
TReaderDataLifecycle(const dds::core::Duration &autopurge_nowriter_samples_delay = dds::core::Duration::infinite(), const dds::core::Duration &autopurge_disposed_samples_delay = dds::core::Duration::infinite())¶
-
template<typename D>
class TDurability : public dds::core::Value<D>¶ - #include <TCorePolicy.hpp>
Public Functions
-
explicit TDurability(dds::core::policy::DurabilityKind::Type kind = dds::core::policy::DurabilityKind::VOLATILE)¶
Creates a Durability QoS instance
- Parameters
kind – the kind
-
TDurability(const TDurability &other)¶
Copies a Durability QoS instance
- Parameters
other – the Durability QoS instance to copy
-
TDurability &operator=(const TDurability &other) = default¶
Copies a Durability QoS instance
- Parameters
other – the Durability QoS instance to copy
- Returns
reference to the Durability QoS that was copied to
-
TDurability &kind(dds::core::policy::DurabilityKind::Type kind)¶
Set the kind
- Parameters
kind – the kind to set
- Returns
the kind that was set
-
dds::core::policy::DurabilityKind::Type kind() const¶
Get the kind
- Returns
the kind
Public Static Functions
-
static TDurability Volatile()¶
- Returns
a Durability QoS instance with the kind set to VOLATILE
-
static TDurability TransientLocal()¶
- Returns
a Durability QoS instance with the kind set to TRANSIENT_LOCAL
-
static TDurability Transient()¶
- Returns
a Durability QoS instance with the kind set to TRANSIENT
-
static TDurability Persistent()¶
- Returns
a Durability QoS instance with the kind set to PERSISTENT
-
explicit TDurability(dds::core::policy::DurabilityKind::Type kind = dds::core::policy::DurabilityKind::VOLATILE)¶
-
template<typename D>
class TPresentation : public dds::core::Value<D>¶ - #include <TCorePolicy.hpp>
Public Functions
-
TPresentation(dds::core::policy::PresentationAccessScopeKind::Type access_scope = dds::core::policy::PresentationAccessScopeKind::INSTANCE, bool coherent_access = false, bool ordered_access = false)¶
Creates a Presentation QoS instance
- Parameters
access_scope – the access_scope kind
coherent_access – the coherent_access setting
ordered_access – the ordered_access setting
-
TPresentation(const TPresentation &other)¶
Copies a Presentation QoS instance
- Parameters
other – the Presentation QoS instance to copy
-
TPresentation &operator=(const TPresentation &other) = default¶
Copies a Presentation QoS instance
- Parameters
other – the Presentation QoS instance to copy
- Returns
reference to the Presentation QoS that was copied to
-
TPresentation &access_scope(dds::core::policy::PresentationAccessScopeKind::Type access_scope)¶
Sets the access_scope kind
- Parameters
access_scope – the access_scope kind
-
dds::core::policy::PresentationAccessScopeKind::Type access_scope() const¶
Gets the access_scope kind
- Returns
the access_scope kind
-
TPresentation &coherent_access(bool coherent_access)¶
Sets the coherent_access setting
- Parameters
coherent_access – the coherent_access setting
-
bool coherent_access() const¶
Gets the coherent_access setting
- Returns
the coherent_access setting
-
TPresentation &ordered_access(bool ordered_access)¶
Sets the ordered_access setting
- Parameters
ordered_access – the ordered_access setting
-
bool ordered_access() const¶
Gets the ordered_access setting
- Returns
the ordered_access setting
Public Static Functions
-
static TPresentation GroupAccessScope(bool coherent_access = false, bool ordered_access = false)¶
- Parameters
coherent_access – the coherent_access setting
ordered_access – the ordered_access setting
- Returns
a Presentation QoS instance with a GROUP access_score and coherent_access and ordered_access set to the specified values
-
static TPresentation InstanceAccessScope(bool coherent_access = false, bool ordered_access = false)¶
- Parameters
coherent_access – the coherent_access setting
ordered_access – the ordered_access setting
- Returns
a Presentation QoS instance with a INSTANCE access_score and coherent_access and ordered_access set to the specified values
-
static TPresentation TopicAccessScope(bool coherent_access = false, bool ordered_access = false)¶
- Parameters
coherent_access – the coherent_access setting
ordered_access – the ordered_access setting
- Returns
a Presentation QoS instance with a TOPIC access_score and coherent_access and ordered_access set to the specified values
-
TPresentation(dds::core::policy::PresentationAccessScopeKind::Type access_scope = dds::core::policy::PresentationAccessScopeKind::INSTANCE, bool coherent_access = false, bool ordered_access = false)¶
-
template<typename D>
class TReliability : public dds::core::Value<D>¶ - #include <TCorePolicy.hpp>
Public Functions
-
TReliability(dds::core::policy::ReliabilityKind::Type kind = dds::core::policy::ReliabilityKind::BEST_EFFORT, const dds::core::Duration &max_blocking_time = dds::core::Duration::from_millisecs(100))¶
Creates a Reliability QoS instance
- Parameters
kind – the kind
max_blocking_time – the max_blocking_time
-
TReliability(const TReliability &other)¶
Copies a Reliability QoS instance
- Parameters
other – the Reliability QoS instance to copy
-
TReliability &operator=(const TReliability &other) = default¶
Copies a Reliability QoS instance
- Parameters
other – the Reliability QoS instance to copy
- Returns
reference to the Reliability QoS that was copied to
-
TReliability &kind(dds::core::policy::ReliabilityKind::Type kind)¶
Sets the kind
- Parameters
kind – the kind
-
dds::core::policy::ReliabilityKind::Type kind() const¶
Gets the kind
- Returns
the kind
-
TReliability &max_blocking_time(const dds::core::Duration &max_blocking_time)¶
Sets the max_blocking_time
- Parameters
max_blocking_time – the max_blocking_time
Public Static Functions
-
static TReliability Reliable(const dds::core::Duration &max_blocking_time = dds::core::Duration::from_millisecs(100))¶
- Parameters
max_blocking_time – the max blocking time
- Returns
a Reliability QoS instance with the kind set to RELIABLE and the max_blocking_time set to the supplied value
-
static TReliability BestEffort(const dds::core::Duration &max_blocking_time = dds::core::Duration::from_millisecs(100))¶
- Returns
a Reliability QoS instance with the kind set to BEST_EFFORT
-
TReliability(dds::core::policy::ReliabilityKind::Type kind = dds::core::policy::ReliabilityKind::BEST_EFFORT, const dds::core::Duration &max_blocking_time = dds::core::Duration::from_millisecs(100))¶
-
template<typename D>
class TDestinationOrder : public dds::core::Value<D>¶ - #include <TCorePolicy.hpp>
Public Functions
-
explicit TDestinationOrder(dds::core::policy::DestinationOrderKind::Type kind = dds::core::policy::DestinationOrderKind::BY_RECEPTION_TIMESTAMP)¶
Creates a DestinationOrder QoS instance
- Parameters
kind – the kind
-
TDestinationOrder(const TDestinationOrder &other)¶
Copies a DestinationOrder QoS instance
- Parameters
other – the DestinationOrder QoS instance to copy
-
TDestinationOrder &operator=(const TDestinationOrder &other) = default¶
Copies a DestinationOrder QoS instance
- Parameters
other – the DestinationOrder QoS instance to copy
- Returns
reference to the DestinationOrder QoS that was copied to
-
TDestinationOrder &kind(dds::core::policy::DestinationOrderKind::Type kind)¶
Sets the kind
- Parameters
kind – the kind
-
dds::core::policy::DestinationOrderKind::Type kind() const¶
Gets the kind
- Returns
the kind
Public Static Functions
-
static TDestinationOrder SourceTimestamp()¶
- Returns
a DestinationOrder QoS instance with the kind set to BY_SOURCE_TIMESTAMP
-
static TDestinationOrder ReceptionTimestamp()¶
- Returns
a DestinationOrder QoS instance with the kind set to BY_RECEPTION_TIMESTAMP
-
explicit TDestinationOrder(dds::core::policy::DestinationOrderKind::Type kind = dds::core::policy::DestinationOrderKind::BY_RECEPTION_TIMESTAMP)¶
-
template<typename D>
class THistory : public dds::core::Value<D>¶ - #include <TCorePolicy.hpp>
Public Functions
-
THistory(dds::core::policy::HistoryKind::Type kind = dds::core::policy::HistoryKind::KEEP_LAST, int32_t depth = 1)¶
Creates a History QoS instance
- Parameters
kind – the kind
depth – the history depth
-
THistory(const THistory &other)¶
Copies a History QoS instance
- Parameters
other – the History QoS instance to copy
-
THistory &operator=(const THistory &other) = default¶
Copies a History QoS instance
- Parameters
other – the History QoS instance to copy
- Returns
reference to the History QoS that was copied to
-
dds::core::policy::HistoryKind::Type kind() const¶
Gets the kind
- Returns
the kind
-
THistory &kind(dds::core::policy::HistoryKind::Type kind)¶
Sets the kind
- Parameters
kind – the kind
-
int32_t depth() const¶
Gets the history depth
- Returns
the history depth
-
THistory(dds::core::policy::HistoryKind::Type kind = dds::core::policy::HistoryKind::KEEP_LAST, int32_t depth = 1)¶
-
template<typename D>
class TResourceLimits : public dds::core::Value<D>¶ - #include <TCorePolicy.hpp>
Public Functions
-
TResourceLimits(int32_t max_samples = dds::core::LENGTH_UNLIMITED, int32_t max_instances = dds::core::LENGTH_UNLIMITED, int32_t max_samples_per_instance = dds::core::LENGTH_UNLIMITED)¶
Creates a ResourceLimits QoS instance
- Parameters
max_samples – the max_samples value
max_instances – the max_instances value
max_samples_per_instance – the max_samples_per_instance value
-
TResourceLimits(const TResourceLimits &other)¶
Copies a ResourceLimits QoS instance
- Parameters
other – the ResourceLimits QoS instance to copy
-
TResourceLimits &operator=(const TResourceLimits &other) = default¶
Copies a ResourceLimits QoS instance
- Parameters
other – the ResourceLimits QoS instance to copy
- Returns
reference to the ResourceLimits QoS that was copied to
-
TResourceLimits &max_samples(int32_t max_samples)¶
Sets the max_samples value
- Parameters
max_samples – the max_samples value
-
int32_t max_samples() const¶
Gets the max_samples value
- Returns
the max_samples value
-
TResourceLimits &max_instances(int32_t max_instances)¶
Sets the max_instances value
- Parameters
max_instances – the max_instances value
-
int32_t max_instances() const¶
Gets the max_instances value
- Returns
the max_instances value
-
TResourceLimits &max_samples_per_instance(int32_t max_samples_per_instance)¶
Sets the max_samples_per_instance value
- Parameters
max_samples_per_instance – the max_samples_per_instance value
-
int32_t max_samples_per_instance() const¶
Gets the max_samples_per_instance value
- Returns
the max_samples_per_instance value
-
TResourceLimits(int32_t max_samples = dds::core::LENGTH_UNLIMITED, int32_t max_instances = dds::core::LENGTH_UNLIMITED, int32_t max_samples_per_instance = dds::core::LENGTH_UNLIMITED)¶
-
template<typename D>
class TLiveliness : public dds::core::Value<D>¶ - #include <TCorePolicy.hpp>
Public Functions
-
TLiveliness(dds::core::policy::LivelinessKind::Type kind = dds::core::policy::LivelinessKind::AUTOMATIC, const dds::core::Duration &lease_duration = dds::core::Duration::infinite())¶
Creates a Liveliness QoS instance
- Parameters
kind – the kind
lease_duration – the lease_duration
-
TLiveliness(const TLiveliness &other)¶
Copies a Liveliness QoS instance
- Parameters
other – the Liveliness QoS instance to copy
-
TLiveliness &operator=(const TLiveliness &other) = default¶
Copies a Liveliness QoS instance
- Parameters
other – the Liveliness QoS instance to copy
- Returns
reference to the Liveliness QoS that was copied to
-
TLiveliness &kind(dds::core::policy::LivelinessKind::Type kind)¶
Sets the kind
- Parameters
kind – the kind
-
dds::core::policy::LivelinessKind::Type kind() const¶
Gets the kind
- Returns
the kind
-
TLiveliness &lease_duration(const dds::core::Duration &lease_duration)¶
Sets the lease_duration
- Returns
the lease_duration
Public Static Functions
-
static TLiveliness Automatic(const dds::core::Duration &lease_duration = dds::core::Duration::infinite())¶
- Returns
a Liveliness QoS instance with the kind set to AUTOMATIC and the lease_duration set to the supplied value
-
TLiveliness(dds::core::policy::LivelinessKind::Type kind = dds::core::policy::LivelinessKind::AUTOMATIC, const dds::core::Duration &lease_duration = dds::core::Duration::infinite())¶
-
template<typename D>
class TPSMXInstances : public dds::core::Value<D>¶ - #include <TCorePolicy.hpp>
QoSPolicy indicating which PSMX instances to use (if present).
Restricts the PSMX instances used for data exchange to the ones in this QoSPolicy, if populated by the user. Populating this QoSPolicy with an empty list means no PSMX exchange will be used. Will be default constructed, but not set as populated in the default constructed DataWriter and DataReader QoSes. In this manner default constructed QoSes will allow all PSMX forms of exchange available to CycloneDDS.
Public Functions
-
TPSMXInstances(const TPSMXInstances &other)¶
Constructs a copy of a TPSMXInstances QoS instance
- Parameters
other – The instance to copy.
-
explicit TPSMXInstances(const dds::core::StringSeq &instances = {})¶
Constructs an initialized TPSMXInstances QoS instance
- Parameters
instances – the PSMX instances to support
-
TPSMXInstances &operator=(const TPSMXInstances &other) = default¶
Copies a TPSMXInstances QoS instance
- Parameters
other – the instance to copy
-
TPSMXInstances &instances(const dds::core::StringSeq &instances)¶
Sets which PSMX instances are supported
- Parameters
instances – which instances to support
- Returns
the psmx instances QoSPolicy that was changed
-
TPSMXInstances(const TPSMXInstances &other)¶
-
template<typename D>
class TQosPolicyCount : public dds::core::Value<D>¶ - #include <TQosPolicyCount.hpp>
The QosPolicyCount object shows, for a QosPolicy, the total number of times that the concerned DataWriter discovered a DataReader for the same Topic and a requested DataReaderQos that is incompatible with the one offered by the DataWriter.
Public Functions
-
TQosPolicyCount(QosPolicyId policy_id, int32_t count)¶
Creates a QosPolicyCount instance
- Parameters
policy_id – the policy_id
count – the count
-
TQosPolicyCount(const TQosPolicyCount &other)¶
Copies a QosPolicyCount instance
- Parameters
other – the QosPolicyCount instance to copy
-
TQosPolicyCount &operator=(const TQosPolicyCount &other) = default¶
Copies a QosPolicyCount instance
- Parameters
other – the QosPolicyCount instance to copy
- Returns
a reference to the QosPolicyCount that was copied to
-
QosPolicyId policy_id() const¶
Gets the policy_id
- Returns
the policy_id
-
int32_t count() const¶
Gets the count
- Returns
the count
-
TQosPolicyCount(QosPolicyId policy_id, int32_t count)¶
-
namespace detail¶
Typedefs
-
typedef dds::core::policy::TDeadline<org::eclipse::cyclonedds::core::policy::DeadlineDelegate> Deadline¶
-
typedef dds::core::policy::TDestinationOrder<org::eclipse::cyclonedds::core::policy::DestinationOrderDelegate> DestinationOrder¶
-
typedef dds::core::policy::TDurability<org::eclipse::cyclonedds::core::policy::DurabilityDelegate> Durability¶
-
typedef dds::core::policy::TEntityFactory<org::eclipse::cyclonedds::core::policy::EntityFactoryDelegate> EntityFactory¶
-
typedef dds::core::policy::TGroupData<org::eclipse::cyclonedds::core::policy::GroupDataDelegate> GroupData¶
-
typedef dds::core::policy::THistory<org::eclipse::cyclonedds::core::policy::HistoryDelegate> History¶
-
typedef dds::core::policy::TLatencyBudget<org::eclipse::cyclonedds::core::policy::LatencyBudgetDelegate> LatencyBudget¶
-
typedef dds::core::policy::TLifespan<org::eclipse::cyclonedds::core::policy::LifespanDelegate> Lifespan¶
-
typedef dds::core::policy::TLiveliness<org::eclipse::cyclonedds::core::policy::LivelinessDelegate> Liveliness¶
-
typedef dds::core::policy::TOwnership<org::eclipse::cyclonedds::core::policy::OwnershipDelegate> Ownership¶
-
typedef dds::core::policy::TPartition<org::eclipse::cyclonedds::core::policy::PartitionDelegate> Partition¶
-
typedef dds::core::policy::TPresentation<org::eclipse::cyclonedds::core::policy::PresentationDelegate> Presentation¶
-
typedef dds::core::policy::TReaderDataLifecycle<org::eclipse::cyclonedds::core::policy::ReaderDataLifecycleDelegate> ReaderDataLifecycle¶
-
typedef dds::core::policy::TReliability<org::eclipse::cyclonedds::core::policy::ReliabilityDelegate> Reliability¶
-
typedef dds::core::policy::TResourceLimits<org::eclipse::cyclonedds::core::policy::ResourceLimitsDelegate> ResourceLimits¶
-
typedef dds::core::policy::TTimeBasedFilter<org::eclipse::cyclonedds::core::policy::TimeBasedFilterDelegate> TimeBasedFilter¶
-
typedef dds::core::policy::TTopicData<org::eclipse::cyclonedds::core::policy::TopicDataDelegate> TopicData¶
-
typedef dds::core::policy::TTransportPriority<org::eclipse::cyclonedds::core::policy::TransportPriorityDelegate> TransportPriority¶
-
typedef dds::core::policy::TPSMXInstances<org::eclipse::cyclonedds::core::policy::PSMXInstancesDelegate> PSMXInstances¶
-
typedef dds::core::policy::TUserData<org::eclipse::cyclonedds::core::policy::UserDataDelegate> UserData¶
-
typedef dds::core::policy::TWriterDataLifecycle<org::eclipse::cyclonedds::core::policy::WriterDataLifecycleDelegate> WriterDataLifecycle¶
-
typedef dds::core::policy::TWriterBatching<org::eclipse::cyclonedds::core::policy::WriterBatchingDelegate> WriterBatching¶
-
typedef dds::core::policy::TQosPolicyCount<org::eclipse::cyclonedds::core::policy::QosPolicyCountDelegate> QosPolicyCount¶
-
typedef dds::core::policy::TDeadline<org::eclipse::cyclonedds::core::policy::DeadlineDelegate> Deadline¶
-
typedef dds::core::policy::detail::DestinationOrder DestinationOrder¶
-
namespace status¶
Typedefs
-
typedef ::dds::core::status::detail::InconsistentTopicStatus InconsistentTopicStatus¶
-
typedef ::dds::core::status::detail::LivelinessChangedStatus LivelinessChangedStatus¶
-
typedef ::dds::core::status::detail::LivelinessLostStatus LivelinessLostStatus¶
-
typedef ::dds::core::status::detail::OfferedDeadlineMissedStatus OfferedDeadlineMissedStatus¶
-
typedef ::dds::core::status::detail::OfferedIncompatibleQosStatus OfferedIncompatibleQosStatus¶
-
typedef ::dds::core::status::detail::PublicationMatchedStatus PublicationMatchedStatus¶
-
typedef ::dds::core::status::detail::SampleRejectedStatus SampleRejectedStatus¶
-
typedef ::dds::core::status::detail::RequestedDeadlineMissedStatus RequestedDeadlineMissedStatus¶
-
typedef ::dds::core::status::detail::RequestedIncompatibleQosStatus RequestedIncompatibleQosStatus¶
-
typedef ::dds::core::status::detail::SampleLostStatus SampleLostStatus¶
-
typedef ::dds::core::status::detail::SubscriptionMatchedStatus SubscriptionMatchedStatus¶
Functions
-
template<typename STATUS>
StatusMask get_status()¶
-
class SampleRejectedState : public std::bitset<OMG_DDS_STATE_BIT_COUNT>¶
- #include <State.hpp>
Class to contain the statistics about samples that have been rejected.
See also
for more information: SampleInfo
Public Types
-
typedef std::bitset<OMG_DDS_STATE_BIT_COUNT> MaskType¶
Convenience typedef for std::bitset<OMG_DDS_STATE_BIT_COUNT>.
Public Functions
-
SampleRejectedState()¶
Construct an empty SampleRejectedState.
-
SampleRejectedState(const SampleRejectedState &src)¶
Copy constructor.
Construct an SampleRejectedState with existing SampleRejectedState.
- Parameters
src – the SampleRejectedState to copy from
-
SampleRejectedState(const MaskType &src)¶
Construct a SampleRejectedState with existing MaskType.
- Parameters
src – the MaskType to copy from
-
SampleRejectedState &operator=(const SampleRejectedState&) = default¶
Copy assignment operator.
Copies the data from src to the current instance.
- Parameters
src – the SampleRejectedState to copy from
- Returns
reference to the SampleRejectedState that was copied to
Public Static Functions
-
static inline SampleRejectedState not_rejected()¶
Get the NOT_REJECTED.
not_rejected
No sample has been rejected yet.
- Returns
the not_rejected SampleRejectedState
-
static inline SampleRejectedState rejected_by_samples_limit()¶
Get the REJECTED_BY_SAMPLES_LIMIT.
rejected_by_samples_limit
The sample was rejected because it would exceed the maximum number of samples set by the ResourceLimits QosPolicy.
- Returns
the rejected_by_samples_limit SampleRejectedState
-
static inline SampleRejectedState rejected_by_instances_limit()¶
Get the REJECTED_BY_INSTANCES_LIMIT.
rejected_by_instances_limit
The sample was rejected because it would exceed the maximum number of instances set by the ResourceLimits QosPolicy.
- Returns
the rejected_by_instances_limit SampleRejectedState
-
static inline SampleRejectedState rejected_by_samples_per_instance_limit()¶
Get the REJECTED_BY_SAMPLES_PER_INSTANCE_LIMIT.
rejected_by_samples_per_instance_limit
The sample was rejected because it would exceed the maximum number of samples per instance set by the ResourceLimits QosPolicy.
- Returns
the rejected_by_samples_per_instance_limit SampleRejectedState
-
typedef std::bitset<OMG_DDS_STATE_BIT_COUNT> MaskType¶
-
class StatusMask : public std::bitset<OMG_DDS_STATUS_COUNT>¶
- #include <State.hpp>
StatusMask is a bitmap or bitset field.
This bitset is used to:
determine which listener functions to call
set conditions in dds::core::cond::StatusCondition
indicate status changes when calling dds::core::Entity::status_changes
See also
for more information: Status concept
Public Types
-
typedef std::bitset<OMG_DDS_STATUS_COUNT> MaskType¶
Convenience typedef for std::bitset<OMG_DDS_STATE_BIT_COUNT>.
Public Functions
-
StatusMask()¶
Construct an StatusMask with no flags set.
-
explicit StatusMask(uint32_t mask)¶
Construct an StatusMask with an uint32_t bit mask.
- Parameters
mask – the bit array to initialize the bitset with
-
StatusMask(const StatusMask &other)¶
Copy constructor.
Construct an StatusMask with existing StatusMask.
- Parameters
other – the StatusMask to copy from
-
StatusMask &operator=(const StatusMask &other) = default¶
Copy assignment operator.
Copies the contents from one StatusMask to another.
- Parameters
other – the StatusMask to copy from
- Returns
reference to the StatusMask that was copied to
-
inline StatusMask &operator<<(const dds::core::status::StatusMask &mask)¶
Shift (merge) given StatusMask bits into this StatusMask bitset.
- Returns
StatusMask this
-
inline StatusMask operator|(const dds::core::status::StatusMask &mask) const¶
Public Static Functions
-
static inline StatusMask all()¶
Get all StatusMasks
- Returns
StatusMask all
-
static inline StatusMask none()¶
Get no StatusMasks
- Returns
StatusMask none
-
static inline StatusMask inconsistent_topic()¶
Get the StatusMask associated with dds::core::status::InconsistentTopicStatus
- Returns
StatusMask inconsistent_topic
-
static inline StatusMask offered_deadline_missed()¶
Get the StatusMask associated with dds::core::status::OfferedDeadlineMissedStatus
- Returns
StatusMask offered_deadline_missed
-
static inline StatusMask requested_deadline_missed()¶
Get the StatusMask associated with dds::core::status::RequestedDeadlineMissedStatus
- Returns
StatusMask requested_deadline_missed
-
static inline StatusMask offered_incompatible_qos()¶
Get the StatusMask associated with dds::core::status::OfferedIncompatibleQosStatus
- Returns
StatusMask offered_incompatible_qos
-
static inline StatusMask requested_incompatible_qos()¶
Get the StatusMask associated with dds::core::status::RequestedIncompatibleQosStatus
- Returns
StatusMask requested_incompatible_qos
-
static inline StatusMask sample_lost()¶
Get the StatusMask associated with dds::core::status::SampleLostStatus
- Returns
StatusMask sample_lost
-
static inline StatusMask sample_rejected()¶
Get the StatusMask associated with dds::core::status::SampleRejectedStatus
- Returns
StatusMask sample_rejected
-
static inline StatusMask data_on_readers()¶
Get the StatusMask associated with dds::core::status::data_on_readers
- Returns
StatusMask data_on_readers
-
static inline StatusMask data_available()¶
get the statusmask associated with dds::core::status::data_available
- Returns
statusmask data_available
-
static inline StatusMask liveliness_lost()¶
Get the StatusMask associated with dds::core::status::LivelinessLostStatus
- Returns
StatusMask liveliness_lost
-
static inline StatusMask liveliness_changed()¶
Get the StatusMask associated with dds::core::status::LivelinessChangedStatus
- Returns
StatusMask liveliness_changed
-
static inline StatusMask publication_matched()¶
Get the statusmask associated with dds::core::status::PublicationMatchedStatus
- Returns
StatusMask publication_matched
-
static inline StatusMask subscription_matched()¶
Get the statusmask associated with dds::core::status::SubscriptionMatchedStatus
- Returns
StatusMask subscription_matched
-
class DataAvailableStatus¶
-
class DataOnReadersStatus¶
-
template<typename D>
class TInconsistentTopicStatus : public dds::core::Value<D>¶ - #include <TStatus.hpp>
-
template<typename D>
class TSampleLostStatus : public dds::core::Value<D>¶ - #include <TStatus.hpp>
Public Functions
-
TSampleLostStatus()¶
-
int32_t total_count() const¶
- Returns
Total cumulative count of all samples lost across of instances of data published under the Topic.
-
int32_t total_count_change() const¶
- Returns
The incremental number of samples lost since the last time the listener was called or the status was read.
-
TSampleLostStatus()¶
-
template<typename D>
class TSampleRejectedStatus : public dds::core::Value<D>¶ - #include <TStatus.hpp>
Public Functions
-
TSampleRejectedStatus()¶
-
int32_t total_count() const¶
- Returns
Total cumulative count of samples rejected by the DataReader.
-
int32_t total_count_change() const¶
- Returns
The incremental number of samples rejected since the last time the listener was called or the status was read.
-
const dds::core::status::SampleRejectedState last_reason() const¶
- Returns
Reason for rejecting the last sample rejected. If no samples have been rejected, the reason is the special value NOT_REJECTED.
-
const dds::core::InstanceHandle last_instance_handle() const¶
- Returns
Handle to the instance being updated by the last sample that was rejected.
-
TSampleRejectedStatus()¶
-
template<typename D>
class TLivelinessLostStatus : public dds::core::Value<D>¶ - #include <TStatus.hpp>
Public Functions
-
TLivelinessLostStatus()¶
-
int32_t total_count() const¶
- Returns
Total cumulative number of times that a previously-alive DataWriter became ‘not alive’ due to a failure to actively signal its liveliness within its offered liveliness period. This count does not change when an already not alive DataWriter simply remains not alive for another liveliness period.
-
int32_t total_count_change() const¶
- Returns
The change in total_count since the last time the listener was called or the status was read.
-
TLivelinessLostStatus()¶
-
template<typename D>
class TLivelinessChangedStatus : public dds::core::Value<D>¶ - #include <TStatus.hpp>
Public Functions
-
TLivelinessChangedStatus()¶
-
int32_t alive_count() const¶
- Returns
The total number of currently active DataWriters that write the Topic read by the DataReader. This count increases when a newly-matched DataWriter asserts its liveliness for the first time or when a DataWriter previously considered to be not alive reasserts its liveliness. The count decreases when a DataWriter considered alive fails to assert its liveliness and becomes not alive, whether because it was deleted normally or for some other reason.
-
int32_t not_alive_count() const¶
- Returns
The total count of currently DataWriters that write the Topic read by the DataReader that are no longer asserting their liveliness. This count increases when a DataWriter considered alive fails to assert its liveliness and becomes not alive for some reason other than the normal deletion of that DataWriter. It decreases when a previously not alive DataWriter either reasserts its liveliness or is deleted normally.
-
int32_t alive_count_change() const¶
- Returns
The change in the alive_count since the last time the listener was called or the status was read.
-
int32_t not_alive_count_change() const¶
- Returns
The change in the not_alive_count since the last time the listener was called or the status was read.
-
const dds::core::InstanceHandle last_publication_handle() const¶
- Returns
Handle to the last DataWriter whose change in liveliness caused this status to change.
-
TLivelinessChangedStatus()¶
-
template<typename D>
class TOfferedDeadlineMissedStatus : public dds::core::Value<D>¶ - #include <TStatus.hpp>
Public Functions
-
TOfferedDeadlineMissedStatus()¶
-
int32_t total_count() const¶
- Returns
Total cumulative number of offered deadline periods elapsed during which a DataWriter failed to provide data. Missed deadlines accumulate; that is, each deadline period the total_count will be incremented by one.
-
int32_t total_count_change() const¶
- Returns
The change in total_count since the last time the listener was called or the status was read.
-
const dds::core::InstanceHandle last_instance_handle() const¶
- Returns
Handle to the last instance in the DataWriter for which an offered deadline was missed.
-
TOfferedDeadlineMissedStatus()¶
-
template<typename D>
class TRequestedDeadlineMissedStatus : public dds::core::Value<D>¶ - #include <TStatus.hpp>
Public Functions
-
TRequestedDeadlineMissedStatus()¶
-
int32_t total_count() const¶
- Returns
Total cumulative number of missed deadlines detected for any instance read by the DataReader. Missed deadlines accumulate; that is, each deadline period the total_count will be incremented by one for each instance for which data was not received.
-
int32_t total_count_change() const¶
- Returns
The incremental number of deadlines detected since the last time the listener was called or the status was read.
-
const dds::core::InstanceHandle last_instance_handle() const¶
- Returns
Handle to the last instance in the DataReader for which a deadline was detected.
-
TRequestedDeadlineMissedStatus()¶
-
template<typename D>
class TOfferedIncompatibleQosStatus : public dds::core::Value<D>¶ - #include <TStatus.hpp>
Public Functions
-
TOfferedIncompatibleQosStatus()¶
-
int32_t total_count() const¶
- Returns
Total cumulative number of times the concerned DataWriter discovered a DataReader for the same Topic with a requested QoS that is incompatible with that offered by the DataWriter.
-
int32_t total_count_change() const¶
- Returns
The change in total_count since the last time the listener was called or the status was read.
-
dds::core::policy::QosPolicyId last_policy_id() const¶
- Returns
The PolicyId of one of the policies that was found to be incompatible the last time an incompatibility was detected.
-
const dds::core::policy::QosPolicyCountSeq policies() const¶
- Returns
A list containing for each policy the total number of times that the concerned DataWriter discovered a DataReader for the same Topic with a requested QoS that is incompatible with that offered by the DataWriter.
-
const dds::core::policy::QosPolicyCountSeq &policies(dds::core::policy::QosPolicyCountSeq &dst) const¶
- Parameters
dst – The destination QosPolicyCountSeq the policies will be returned to
- Returns
A list containing for each policy the total number of times that the concerned DataWriter discovered a DataReader for the same Topic with a requested QoS that is incompatible with that offered by the DataWriter.
-
TOfferedIncompatibleQosStatus()¶
-
template<typename D>
class TRequestedIncompatibleQosStatus : public dds::core::Value<D>¶ - #include <TStatus.hpp>
Public Functions
-
TRequestedIncompatibleQosStatus()¶
-
int32_t total_count() const¶
- Returns
Total cumulative number of times the concerned DataReader discovered a DataWriter for the same Topic with an offered QoS that was incompatible with that requested by the DataReader.
-
int32_t total_count_change() const¶
- Returns
The change in total_count since the last time the listener was called or the status was read.
-
dds::core::policy::QosPolicyId last_policy_id() const¶
- Returns
The QosPolicyId of one of the policies that was found to be incompatible the last time an incompatibility was detected.
-
const dds::core::policy::QosPolicyCountSeq policies() const¶
- Returns
A list containing for each policy the total number of times that the concerned DataReader discovered a DataWriter for the same Topic with an offered QoS that is incompatible with that requested by the DataReader.
-
const dds::core::policy::QosPolicyCountSeq &policies(dds::core::policy::QosPolicyCountSeq &dst) const¶
- Parameters
dst – The destination QosPolicyCountSeq the policies will be returned to
- Returns
A list containing for each policy the total number of times that the concerned DataReader discovered a DataWriter for the same Topic with an offered QoS that is incompatible with that requested by the DataReader.
-
TRequestedIncompatibleQosStatus()¶
-
template<typename D>
class TPublicationMatchedStatus : public dds::core::Value<D>¶ - #include <TStatus.hpp>
Public Functions
-
TPublicationMatchedStatus()¶
-
int32_t total_count() const¶
- Returns
Total cumulative count the concerned DataWriter discovered a “match” with a DataReader. That is, it found a DataReader for the same Topic with a requested QoS that is compatible with that offered by the DataWriter.
-
int32_t total_count_change() const¶
- Returns
The change in total_count since the last time the listener was called or the status was read.
-
int32_t current_count() const¶
- Returns
The number of DataReaders currently matched to the concerned DataWriter.
-
int32_t current_count_change() const¶
- Returns
The change in current_count since the last time the listener was called or the status was read.
-
const dds::core::InstanceHandle last_subscription_handle() const¶
- Returns
Handle to the last DataReader that matched the DataWriter causing the status to change.
-
TPublicationMatchedStatus()¶
-
template<typename D>
class TSubscriptionMatchedStatus : public dds::core::Value<D>¶ - #include <TStatus.hpp>
Public Functions
-
TSubscriptionMatchedStatus()¶
-
int32_t total_count() const¶
- Returns
Total cumulative count the concerned DataReader discovered a “match” with a DataWriter. That is, it found a DataWriter for the same Topic with a requested QoS that is compatible with that offered by the DataReader.
-
int32_t total_count_change() const¶
- Returns
The change in total_count since the last time the listener was called or the status was read.
-
int32_t current_count() const¶
- Returns
The number of DataWriters currently matched to the concerned DataReader.
-
int32_t current_count_change() const¶
- Returns
The change in current_count since the last time the listener was called or the status was read.
-
const dds::core::InstanceHandle last_publication_handle() const¶
- Returns
Handle to the last DataWriter that matched the DataReader causing the status to change.
-
TSubscriptionMatchedStatus()¶
-
namespace detail¶
Typedefs
-
typedef dds::core::status::TInconsistentTopicStatus<org::eclipse::cyclonedds::core::InconsistentTopicStatusDelegate> InconsistentTopicStatus¶
-
typedef dds::core::status::TLivelinessChangedStatus<org::eclipse::cyclonedds::core::LivelinessChangedStatusDelegate> LivelinessChangedStatus¶
-
typedef dds::core::status::TLivelinessLostStatus<org::eclipse::cyclonedds::core::LivelinessLostStatusDelegate> LivelinessLostStatus¶
-
typedef dds::core::status::TOfferedDeadlineMissedStatus<org::eclipse::cyclonedds::core::OfferedDeadlineMissedStatusDelegate> OfferedDeadlineMissedStatus¶
-
typedef dds::core::status::TOfferedIncompatibleQosStatus<org::eclipse::cyclonedds::core::OfferedIncompatibleQosStatusDelegate> OfferedIncompatibleQosStatus¶
-
typedef dds::core::status::TPublicationMatchedStatus<org::eclipse::cyclonedds::core::PublicationMatchedStatusDelegate> PublicationMatchedStatus¶
-
typedef dds::core::status::TSampleRejectedStatus<org::eclipse::cyclonedds::core::SampleRejectedStatusDelegate> SampleRejectedStatus¶
-
typedef dds::core::status::TRequestedDeadlineMissedStatus<org::eclipse::cyclonedds::core::RequestedDeadlineMissedStatusDelegate> RequestedDeadlineMissedStatus¶
-
typedef dds::core::status::TRequestedIncompatibleQosStatus<org::eclipse::cyclonedds::core::RequestedIncompatibleQosStatusDelegate> RequestedIncompatibleQosStatus¶
-
typedef dds::core::status::TSampleLostStatus<org::eclipse::cyclonedds::core::SampleLostStatusDelegate> SampleLostStatus¶
-
typedef dds::core::status::TSubscriptionMatchedStatus<org::eclipse::cyclonedds::core::SubscriptionMatchedStatusDelegate> SubscriptionMatchedStatus¶
-
typedef dds::core::status::TInconsistentTopicStatus<org::eclipse::cyclonedds::core::InconsistentTopicStatusDelegate> InconsistentTopicStatus¶
-
typedef ::dds::core::status::detail::InconsistentTopicStatus InconsistentTopicStatus¶
-
typedef dds::core::detail::InstanceHandle InstanceHandle¶