21 #ifndef OSPL_DDS_CORE_REFERENCE_IMPL_HPP_ 22 #define OSPL_DDS_CORE_REFERENCE_IMPL_HPP_ 32 #include <org/opensplice/core/ReportUtils.hpp> 35 template <
typename DELEGATE>
40 template <
typename DELEGATE>
45 template <
typename DELEGATE>
49 ISOCPP_REPORT_STACK_DDS_BEGIN(*
this);
50 impl_ = OSPL_CXX11_STD_MODULE::dynamic_pointer_cast<DELEGATE_T>(ref.impl_);
51 if (impl_ != ref.impl_) {
56 template <
typename DELEGATE>
61 template <
typename DELEGATE>
67 template <
typename DELEGATE>
72 template <
typename DELEGATE>
75 ISOCPP_REPORT_STACK_NC_BEGIN();
76 ISOCPP_BOOL_CHECK_AND_THROW(impl_, ISOCPP_NULL_REFERENCE_ERROR,
"Reference[%d] == dds::core::null", __LINE__);
80 template <
typename DELEGATE>
85 ISOCPP_REPORT_STACK_DDS_BEGIN(*
this);
87 if (this->
is_nil() && ref.is_nil()) {
90 }
else if (!this->
is_nil() && !ref.is_nil()) {
92 equal = (this->delegate() == ref.delegate());
97 template <
typename DELEGATE>
102 ISOCPP_REPORT_STACK_DDS_BEGIN(*
this);
103 return !(*
this == ref);
106 template <
typename DELEGATE>
107 template <
typename D>
119 template <
typename DELEGATE>
120 template <
typename R>
132 template <
typename DELEGATE>
141 template <
typename DELEGATE>
145 return impl_.get() == 0;
148 template <
typename DELEGATE>
155 template <
typename DELEGATE>
162 template <
typename DELEGATE>
166 ISOCPP_BOOL_CHECK_AND_THROW(impl_, ISOCPP_NULL_REFERENCE_ERROR,
"Reference[%d] == dds::core::null", __LINE__);
170 template <
typename DELEGATE>
174 ISOCPP_BOOL_CHECK_AND_THROW(impl_, ISOCPP_NULL_REFERENCE_ERROR,
"Reference[%d] == dds::core::null", __LINE__);
178 template <
typename DELEGATE>
182 ISOCPP_BOOL_CHECK_AND_THROW(impl_, ISOCPP_NULL_REFERENCE_ERROR,
"Reference[%d] == dds::core::null", __LINE__);
186 template <
typename DELEGATE>
190 ISOCPP_BOOL_CHECK_AND_THROW(impl_, ISOCPP_NULL_REFERENCE_ERROR,
"Reference[%d] == dds::core::null", __LINE__);
194 template <
typename DELEGATE>
198 ISOCPP_BOOL_CHECK_AND_THROW(impl_, ISOCPP_NULL_REFERENCE_ERROR,
"Reference[%d] == dds::core::null", __LINE__);
202 template <
typename DELEGATE>
206 ISOCPP_BOOL_CHECK_AND_THROW(impl_, ISOCPP_NULL_REFERENCE_ERROR,
"Reference[%d] == dds::core::null", __LINE__);
210 template <
typename DELEGATE>
Exception: An operation was invoked on an inappropriate object or at an inappropriate time...
void value(DDT &dd, uint32_t mid, const T &v)
Reference & operator=(const Reference< D > &that)
This class is used to create dds::core::null objects.
#define OMG_DDS_STATIC_ASSERT
bool operator!=(const R &ref) const
Base class for reference-counted objects.
bool operator==(const R &ref) const