MDSTk Libraries  1.1.0
Medical Data Segmentation Toolkit
Classes | Public Types | Static Public Member Functions | Protected Member Functions
mds::base::CSmallObjectBase< C, M, A > Class Template Reference

Base class for small object allocation classes. More...

#include <mdsSmallObject.h>

Inheritance diagram for mds::base::CSmallObjectBase< C, M, A >:
Inheritance graph
[legend]

List of all members.

Classes

struct  SMyAllocator
 Structure holding a small object allocator.

Public Types

typedef CLibraryLockableClass
< CSmallObjectBase< C, M, A >
>::CLock 
tLock
 Lock type.

Static Public Member Functions

static void lock ()
 Locks the object.
static void operator delete (void *p, std::size_t Size)
 Deallocates small object.
static void operator delete (void *p, void *pPlace)
 Placement single-object delete merely calls global placement delete.
static void operator delete[] (void *p, std::size_t Size)
 Deallocates array-object.
static void operator delete[] (void *p, void *pPlace)
 Placement array-object delete merely calls global placement delete.
static void * operator new (std::size_t Size)
 Allocates a small object.
static void * operator new (std::size_t Size, void *pPlace)
 Placement single-object new merely calls global placement new.
static void * operator new[] (std::size_t Size)
 Allocates array-object.
static void * operator new[] (std::size_t Size, void *pPlace)
 Placement array-object new merely calls global placement new.
static void unlock ()
 Locks the object.

Protected Member Functions

 CSmallObjectBase ()
 Protected default constructor.
 CSmallObjectBase (const CSmallObjectBase &)
 Protected copy constructor.
CSmallObjectBaseoperator= (const CSmallObjectBase &)
 Protected assignment operator.
 ~CSmallObjectBase ()
 Protected destructor.

Detailed Description

template<tSize C, tSize M, tSize A>
class mds::base::CSmallObjectBase< C, M, A >

Base class for small object allocation classes.

The shared implementation of the new and delete operators are here instead of being duplicated in both CSmallObject or CSmallValueObject. This class is not meant to be used directly by clients, or derived from by clients.


Member Typedef Documentation

template<tSize C, tSize M, tSize A>
typedef CLibraryLockableClass<CSmallObjectBase<C,M,A> >::CLock mds::base::CSmallObjectBase< C, M, A >::tLock

Lock type.


Constructor & Destructor Documentation

template<tSize C, tSize M, tSize A>
mds::base::CSmallObjectBase< C, M, A >::CSmallObjectBase ( ) [protected]

Protected default constructor.

template<tSize C, tSize M, tSize A>
mds::base::CSmallObjectBase< C, M, A >::CSmallObjectBase ( const CSmallObjectBase< C, M, A > &  ) [protected]

Protected copy constructor.

template<tSize C, tSize M, tSize A>
mds::base::CSmallObjectBase< C, M, A >::~CSmallObjectBase ( ) [protected]

Protected destructor.


Member Function Documentation

static void mds::base::CLockableClass< CSmallObjectBase< C, M, A > >::lock ( ) [static, inherited]

Locks the object.

template<tSize C, tSize M, tSize A>
static void mds::base::CSmallObjectBase< C, M, A >::operator delete ( void *  p,
std::size_t  Size 
) [static]

Deallocates small object.

template<tSize C, tSize M, tSize A>
static void mds::base::CSmallObjectBase< C, M, A >::operator delete ( void *  p,
void *  pPlace 
) [static]

Placement single-object delete merely calls global placement delete.

template<tSize C, tSize M, tSize A>
static void mds::base::CSmallObjectBase< C, M, A >::operator delete[] ( void *  p,
std::size_t  Size 
) [static]

Deallocates array-object.

template<tSize C, tSize M, tSize A>
static void mds::base::CSmallObjectBase< C, M, A >::operator delete[] ( void *  p,
void *  pPlace 
) [static]

Placement array-object delete merely calls global placement delete.

template<tSize C, tSize M, tSize A>
static void* mds::base::CSmallObjectBase< C, M, A >::operator new ( std::size_t  Size) [static]

Allocates a small object.

template<tSize C, tSize M, tSize A>
static void* mds::base::CSmallObjectBase< C, M, A >::operator new ( std::size_t  Size,
void *  pPlace 
) [static]

Placement single-object new merely calls global placement new.

template<tSize C, tSize M, tSize A>
static void* mds::base::CSmallObjectBase< C, M, A >::operator new[] ( std::size_t  Size) [static]

Allocates array-object.

template<tSize C, tSize M, tSize A>
static void* mds::base::CSmallObjectBase< C, M, A >::operator new[] ( std::size_t  Size,
void *  pPlace 
) [static]

Placement array-object new merely calls global placement new.

template<tSize C, tSize M, tSize A>
CSmallObjectBase& mds::base::CSmallObjectBase< C, M, A >::operator= ( const CSmallObjectBase< C, M, A > &  ) [protected]

Protected assignment operator.

static void mds::base::CLockableClass< CSmallObjectBase< C, M, A > >::unlock ( ) [static, inherited]

Locks the object.


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