HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
UT_ScopedArray< T > Class Template Reference

A smart pointer for unique ownership of dynamically allocated arrays. More...

#include <UT_ScopedArray.h>

+ Inheritance diagram for UT_ScopedArray< T >:

Public Member Functions

 UT_ScopedArray (T *p=0)
 

Detailed Description

template<class T>
class UT_ScopedArray< T >

A smart pointer for unique ownership of dynamically allocated arrays.

UT_ScopedArray stores a pointer to a dynamically allocated array, without reference counting. The array pointed to is guaranteed to be deleted, either upon destruction, or via an explicit reset. UT_ScopedArray is a simple solution for simple needs; use UT_SharedArray if your needs are more complex.

As this is a wrapper around the hboost::scoped_array template, the type (T) must have a Copy Constructor and a valid Assignment Operator.

Definition at line 31 of file UT_ScopedArray.h.

Constructor & Destructor Documentation

template<class T >
UT_ScopedArray< T >::UT_ScopedArray ( T p = 0)
inline

Definition at line 35 of file UT_ScopedArray.h.


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