ATLAS Offline Software
Public Types | Public Member Functions | Protected Attributes | List of all members
SG::ArenaHandleBaseAllocT< ALLOC >::Creator Class Reference

Concrete ArenaAllocatorCreator class used to create the Allocator for this handle. More...

Inheritance diagram for SG::ArenaHandleBaseAllocT< ALLOC >::Creator:
Collaboration diagram for SG::ArenaHandleBaseAllocT< ALLOC >::Creator:

Public Types

typedef std::unique_ptr< ArenaAllocatorBasemakeFunc_t(const typename ALLOC::Params &)
 Type for m_makeFunc — a function returning a new Allocator from a parameters structure. More...
 

Public Member Functions

 Creator (const std::string &name, makeFunc_t *makeFunc, const typename ALLOC::Params &params)
 Constructor. More...
 
virtual std::unique_ptr< ArenaAllocatorBasecreate ()
 Create an allocator instance. More...
 
const std::string & name () const
 Return the name of the Allocator we create. More...
 

Protected Attributes

makeFunc_tm_makeFunc
 Function that creates an Allocator given a set of parameters. More...
 
ALLOC::Params m_params
 Set of parameters to use to create our allocator. More...
 

Detailed Description

template<typename ALLOC>
class SG::ArenaHandleBaseAllocT< ALLOC >::Creator

Concrete ArenaAllocatorCreator class used to create the Allocator for this handle.

There are two members of this class: m_makeFunc is the function which actually creates the Allocator, and m_params is the parameters structure to pass to the new Allocator. These will get filled in by ArenaAllocatorCreatorInit, which derives from this.

Definition at line 132 of file ArenaHandleBaseAllocT.h.

Member Typedef Documentation

◆ makeFunc_t

template<typename ALLOC >
typedef std::unique_ptr<ArenaAllocatorBase> SG::ArenaHandleBaseAllocT< ALLOC >::Creator::makeFunc_t(const typename ALLOC::Params &)

Type for m_makeFunc — a function returning a new Allocator from a parameters structure.

Definition at line 139 of file ArenaHandleBaseAllocT.h.

Constructor & Destructor Documentation

◆ Creator()

template<typename ALLOC >
SG::ArenaHandleBaseAllocT< ALLOC >::Creator::Creator ( const std::string &  name,
makeFunc_t makeFunc,
const typename ALLOC::Params &  params 
)

Constructor.

Parameters
nameName of the Allocator.
makeFuncFunction that creates an Allocator given a set of parameters.
paramsAllocator parameters.

This initializes the Creator for creating an Allocator. The name in params will be replaced with the name argument.

Member Function Documentation

◆ create()

template<typename ALLOC >
virtual std::unique_ptr<ArenaAllocatorBase> SG::ArenaHandleBaseAllocT< ALLOC >::Creator::create ( )
virtual

Create an allocator instance.

Implements SG::ArenaAllocatorCreator.

◆ name()

template<typename ALLOC >
const std::string& SG::ArenaHandleBaseAllocT< ALLOC >::Creator::name ( ) const

Return the name of the Allocator we create.

Member Data Documentation

◆ m_makeFunc

template<typename ALLOC >
makeFunc_t* SG::ArenaHandleBaseAllocT< ALLOC >::Creator::m_makeFunc
protected

Function that creates an Allocator given a set of parameters.

Definition at line 170 of file ArenaHandleBaseAllocT.h.

◆ m_params

template<typename ALLOC >
ALLOC::Params SG::ArenaHandleBaseAllocT< ALLOC >::Creator::m_params
protected

Set of parameters to use to create our allocator.

Definition at line 173 of file ArenaHandleBaseAllocT.h.


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