Roc Toolkit internal modules
Roc Toolkit: real-time audio streaming
Loading...
Searching...
No Matches
roc::core::FactoryAllocation< Factory > Class Template Reference

Allocation policy for objects (de)allocated using speciailized factory. More...

#include <allocation_policy.h>

Public Member Functions

 FactoryAllocation ()
 Initialize in invalid state. Such instance wont be usable.
 
 FactoryAllocation (Factory &factory)
 Initialize with given factory. Such instance will use factory to destroy objects.
 
template<class T >
void destroy (T &object)
 Destroy object and deallocate its memory.
 

Protected Member Functions

Factory & factory () const
 Get factory.
 

Detailed Description

template<class Factory>
class roc::core::FactoryAllocation< Factory >

Allocation policy for objects (de)allocated using speciailized factory.

Definition at line 58 of file allocation_policy.h.

Constructor & Destructor Documentation

◆ FactoryAllocation() [1/2]

template<class Factory >
roc::core::FactoryAllocation< Factory >::FactoryAllocation ( )
inline

Initialize in invalid state. Such instance wont be usable.

Definition at line 62 of file allocation_policy.h.

◆ FactoryAllocation() [2/2]

template<class Factory >
roc::core::FactoryAllocation< Factory >::FactoryAllocation ( Factory &  factory)
inline

Initialize with given factory. Such instance will use factory to destroy objects.

Definition at line 68 of file allocation_policy.h.

Member Function Documentation

◆ destroy()

template<class Factory >
template<class T >
void roc::core::FactoryAllocation< Factory >::destroy ( T &  object)
inline

Destroy object and deallocate its memory.

Definition at line 73 of file allocation_policy.h.

◆ factory()

template<class Factory >
Factory & roc::core::FactoryAllocation< Factory >::factory ( ) const
inlineprotected

Get factory.

Definition at line 82 of file allocation_policy.h.


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