Teuchos_RefCountPtrDecl.hpp File Reference

Reference-counted pointer class and non-member templated function definitions. More...

#include "Teuchos_any.hpp"

Include dependency graph for Teuchos_RefCountPtrDecl.hpp:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  Teuchos
namespace  Teuchos::PrivateUtilityPack

Classes

class  Teuchos::DeallocDelete< T >
 Deallocator for new which calls delete. More...
class  Teuchos::DeallocArrayDelete< T >
 Deallocator for new [] which calls delete []. More...
class  Teuchos::RefCountPtr< T >
  More...

Enumerations

enum  ENull
 Used to initialize a RefCountPtr object to NULL using an implicit conversion! More...
enum  EPrePostDestruction
 Used to specify a pre or post destruction of extra data. More...

Functions

template<class T>
RefCountPtr< T > rcp (T *p, bool owns_mem=true)
 Create a RefCountPtr object properly typed.
template<class T, class Dealloc_T>
RefCountPtr< T > rcp (T *p, Dealloc_T dealloc, bool owns_mem)
 Initialize from a raw pointer with a deallocation policy.
template<class T>
bool is_null (const RefCountPtr< T > &p)
 Returns true if p.get()==NULL.
template<class T>
bool operator== (const RefCountPtr< T > &p, ENull)
 Returns true if p.get()==NULL.
template<class T>
bool operator!= (const RefCountPtr< T > &p, ENull)
 Returns true if p.get()!=NULL.
template<class T1, class T2>
bool operator== (const RefCountPtr< T1 > &p1, const RefCountPtr< T2 > &p2)
 Return true if two RefCountPtr objects point to the same referenced-counted object and have the same node.
template<class T1, class T2>
bool operator!= (const RefCountPtr< T1 > &p1, const RefCountPtr< T2 > &p2)
 Return true if two RefCountPtr objects do not point to the same referenced-counted object and have the same node.
template<class T2, class T1>
RefCountPtr< T2 > rcp_implicit_cast (const RefCountPtr< T1 > &p1)
 Implicit cast of underlying RefCountPtr type from T1* to T2*.
template<class T2, class T1>
RefCountPtr< T2 > rcp_static_cast (const RefCountPtr< T1 > &p1)
 Static cast of underlying RefCountPtr type from T1* to T2*.
template<class T2, class T1>
RefCountPtr< T2 > rcp_const_cast (const RefCountPtr< T1 > &p1)
 Constant cast of underlying RefCountPtr type from T1* to T2*.
template<class T2, class T1>
RefCountPtr< T2 > rcp_dynamic_cast (const RefCountPtr< T1 > &p1, bool throw_on_fail=false)
 Dynamic cast of underlying RefCountPtr type from T1* to T2*.
template<class T1, class T2>
void set_extra_data (const T1 &extra_data, const std::string &name, RefCountPtr< T2 > *p, bool force_unique=true, EPrePostDestruction destroy_when=POST_DESTROY)
 Set extra data associated with a RefCountPtr object.
template<class T1, class T2>
T1 & get_extra_data (RefCountPtr< T2 > &p, const std::string &name)
 Get a non-const reference to extra data associated with a RefCountPtr object.
template<class T1, class T2>
const T1 & get_extra_data (const RefCountPtr< T2 > &p, const std::string &name)
 Get a const reference to extra data associated with a RefCountPtr object.
template<class T1, class T2>
T1 * get_optional_extra_data (RefCountPtr< T2 > &p, const std::string &name)
 Get a pointer to non-const extra data (if it exists) associated with a RefCountPtr object.
template<class T1, class T2>
const T1 * get_optional_extra_data (const RefCountPtr< T2 > &p, const std::string &name)
 Get a pointer to const extra data (if it exists) associated with a RefCountPtr object.
template<class Dealloc_T, class T>
Dealloc_T & get_dealloc (RefCountPtr< T > &p)
 Return a non-const reference to the underlying deallocator object.
template<class Dealloc_T, class T>
const Dealloc_T & get_dealloc (const RefCountPtr< T > &p)
 Return a const reference to the underlying deallocator object.
template<class Dealloc_T, class T>
Dealloc_T * get_optional_dealloc (RefCountPtr< T > &p)
 Return a pointer to the underlying non-const deallocator object if it exists.
template<class Dealloc_T, class T>
const Dealloc_T * get_optional_dealloc (const RefCountPtr< T > &p)
 Return a pointer to the underlying const deallocator object if it exists.


Detailed Description

Reference-counted pointer class and non-member templated function definitions.

Definition in file Teuchos_RefCountPtrDecl.hpp.


Generated on Thu Sep 18 12:39:11 2008 for Teuchos - Trilinos Tools Package by doxygen 1.3.9.1