Vuo  2.3.2
Classes | Macros
VuoPool.hh File Reference

Description

VuoPool interface and implementation.

Definition in file VuoPool.hh.

Go to the source code of this file.

Classes

class  VuoKeyedPool< KeyType, InstanceType >
 A pool of shared objects — one object per key. More...
 

Macros

#define VUOKEYEDPOOL(keyType, instanceType)   extern VuoKeyedPool<keyType, instanceType> * instanceType ## Pool
 Declares a VuoKeyedPool instance. More...
 
#define VUOKEYEDPOOL_DEFINE(keyType, instanceType, allocate)   VuoKeyedPool<keyType, instanceType> * instanceType ## Pool = new VuoKeyedPool<keyType, instanceType>(#instanceType, allocate)
 Defines a VuoKeyedPool instance. More...
 

Macro Definition Documentation

◆ VUOKEYEDPOOL

#define VUOKEYEDPOOL (   keyType,
  instanceType 
)    extern VuoKeyedPool<keyType, instanceType> * instanceType ## Pool

Declares a VuoKeyedPool instance.

Definition at line 47 of file VuoPool.hh.

◆ VUOKEYEDPOOL_DEFINE

#define VUOKEYEDPOOL_DEFINE (   keyType,
  instanceType,
  allocate 
)    VuoKeyedPool<keyType, instanceType> * instanceType ## Pool = new VuoKeyedPool<keyType, instanceType>(#instanceType, allocate)

Defines a VuoKeyedPool instance.

Parameters
keyTypeThe C or C++ type to be used as this pool's key.
instanceTypeThe C or C++ type for this pool's objects.
allocateA callback function to allocate and initialize a shared object. The deallocation function (passed to VuoRegister in the allocate function) should call removeSharedInstance before deinitializing and deallocating the object.

Definition at line 56 of file VuoPool.hh.