Blender  V3.3
Public Types | Public Member Functions | Public Attributes | List of all members
GHOST_C_CustomDataWrapper Struct Reference

#include <GHOST_Util.h>

Public Types

using FreeFn = std::function< void(void *)>
 

Public Member Functions

 GHOST_C_CustomDataWrapper (void *custom_data, FreeFn free_fn)
 
 ~GHOST_C_CustomDataWrapper ()
 

Public Attributes

voidcustom_data_
 
FreeFn free_fn_
 

Detailed Description

RAII wrapper for typical C void * custom data. Used for exception safe custom-data handling during constructor calls.

Definition at line 15 of file GHOST_Util.h.

Member Typedef Documentation

◆ FreeFn

using GHOST_C_CustomDataWrapper::FreeFn = std::function<void(void *)>

Definition at line 16 of file GHOST_Util.h.

Constructor & Destructor Documentation

◆ GHOST_C_CustomDataWrapper()

GHOST_C_CustomDataWrapper::GHOST_C_CustomDataWrapper ( void custom_data,
FreeFn  free_fn 
)
inline

Definition at line 21 of file GHOST_Util.h.

◆ ~GHOST_C_CustomDataWrapper()

GHOST_C_CustomDataWrapper::~GHOST_C_CustomDataWrapper ( )
inline

Definition at line 25 of file GHOST_Util.h.

References custom_data_, and free_fn_.

Member Data Documentation

◆ custom_data_

void* GHOST_C_CustomDataWrapper::custom_data_

Definition at line 18 of file GHOST_Util.h.

Referenced by ~GHOST_C_CustomDataWrapper().

◆ free_fn_

FreeFn GHOST_C_CustomDataWrapper::free_fn_

Definition at line 19 of file GHOST_Util.h.

Referenced by ~GHOST_C_CustomDataWrapper().


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