RTI Connext Modern C++ API  Version 5.2.0
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
rti::core::pointer< T > Class Template Reference

#include <Pointer.hpp>

Public Member Functions

 pointer () OMG_NOEXCEPT
 
 pointer (T *ptr) OMG_NOEXCEPT
 
void set (T *ptr) OMG_NOEXCEPT
 
T * get () const OMG_NOEXCEPT
 
pointer< T > & operator= (T *other) OMG_NOEXCEPT
 
bool operator== (const pointer< T > &other) const
 
bool operator!= (const pointer< T > &other) const
 

Detailed Description

template<typename T>
class rti::core::pointer< T >

Helper class for generated types that contain IDL pointers (an RTI extension)

It wraps a loaned pointer and provides overloads of certain operators to access the contents rather than the pointer. It never deep-copies or deletes the underlying pointer.

Constructor & Destructor Documentation

template<typename T >
rti::core::pointer< T >::pointer ( )
inline

Initialize to NULL

template<typename T >
rti::core::pointer< T >::pointer ( T *  ptr)
inline

Shallow-copy the pointer and allow automatic conversion from T *

Member Function Documentation

template<typename T >
void rti::core::pointer< T >::set ( T *  ptr)
inline

Set the underlying pointer. This function does not copy or delete, it just replaces this pointer.

template<typename T >
T* rti::core::pointer< T >::get ( ) const
inline

Returns the underlying pointer

template<typename T >
pointer<T>& rti::core::pointer< T >::operator= ( T *  other)
inline

Assign another pointer replacing the current one

template<typename T >
bool rti::core::pointer< T >::operator== ( const pointer< T > &  other) const
inline

Deep equality comparison

template<typename T >
bool rti::core::pointer< T >::operator!= ( const pointer< T > &  other) const
inline

Deep inequality comparison


RTI Connext Modern C++ API Version 5.2.0 Copyright © Sun Jun 21 2015 Real-Time Innovations, Inc