Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
p6heappool.h
Go to the documentation of this file.
1 
15 #ifndef P6HEAPPOOL_H__
16 #define P6HEAPPOOL_H__ 1
17 
18 #include "p6mempool.h"
19 
20 
21 #ifdef __cplusplus
22 namespace P6R {
23 extern "C" {
24 #endif
25 
33  typedef struct {
41  } P6HEAPPOOLENT;
42 
43  typedef struct {
53 
54 #undef INTERFACE
55 #define INTERFACE p6IHeapPool
57  {
75  P6DECLCOMMETHOD(initialize)(P6THIS_ P6HEAPPOOLENT *pPooDef,P6UINT32 cPoolDef,MEMPOOLFLGS fFlags,const P6WCHAR *pszName) P6PURE;
76 
91  P6DECLCOMMETHOD(alloc)(P6THIS_ P6SIZE nBytes,P6VOID **ppMem) P6PURE;
92 
103  P6DECLCOMMETHOD(free)(P6THIS_ P6VOID *pMem) P6PURE;
104 
105 
106  P6DECLCOMMETHOD(getstats)(P6THIS_ P6HEAPPOOLSTATSENT *pStats,P6UINT32 *pcStats) P6PURE;
107 
108  };
109 
110  // {C5CF1068-A704-4A74-B619-640196B05CE8}
111  #define IF_p6IHeapPool {0xC5CF1068,0xA704,0x4A74,{0xB6,0x19,0x64,0x01,0x96,0xB0,0x5C,0xE8}}
112 
113  // {F431B1E6-8EAE-4AE9-8F65-8F5DC451DB08}
114  #define COMP_p6HeapPool {0xF431B1E6,0x8EAE,0x4AE9,{0x8F,0x65,0x8F,0x5D,0xC4,0x51,0xDB,0x08}}
115 
116 #ifdef __cplusplus
117 }
118 } // namespace
119 #endif
120 
121 
122 #endif
123 
124 
125 
126 
P6UINT32 cInitialCount
The initial number of allocation units to allocate.
Definition: p6heappool.h:35
size_t P6SIZE
Definition: p6types.h:90
uint32_t P6UINT32
Definition: p6types.h:77
P6UINT32 MEMPOOLFLGS
Definition: p6mempool.h:31
#define P6PURE
Definition: p6defs.h:192
An array of these structures are passed to p6IHeapPool::initialize(), each element of which defines t...
Definition: p6heappool.h:33
P6UINT32 cGrowBy
The number of allocation units to grow the pool by if it runs out of allocation units.
Definition: p6heappool.h:36
wchar_t P6WCHAR
Wide character type see p6i18n.h.
Definition: p6types.h:111
The base interface all [p6]COM components must derive from and implement.
Definition: p6comdef.h:97
P6UINT32 cBlockSize
The size in bytes of the allocation unit this pool will use.
Definition: p6heappool.h:34
#define P6MEMPOOL_NAME_MAX
Definition: p6mempool.h:26
#define P6DECLCOMMETHOD(method)
Definition: p6defs.h:189
#define P6THIS_
Definition: p6defs.h:193
Fixed-size, pool based, memory allocator.
void P6VOID
Definition: p6types.h:109
#define P6DECLAREIF_(iface, baseif)
Definition: p6defs.h:188