ACE  6.1.7
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions
ACE_Malloc< ACE_MEM_POOL_1, ACE_LOCK > Class Template Reference

#include <Malloc_T.h>

Inheritance diagram for ACE_Malloc< ACE_MEM_POOL_1, ACE_LOCK >:
Inheritance graph
[legend]
Collaboration diagram for ACE_Malloc< ACE_MEM_POOL_1, ACE_LOCK >:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 ACE_Malloc (const ACE_TCHAR *pool_name=0)
 ACE_Malloc (const ACE_TCHAR *pool_name, const ACE_TCHAR *lock_name, const ACE_MEM_POOL_OPTIONS *options=0)
- Public Member Functions inherited from ACE_Malloc_T< ACE_MEM_POOL_2, ACE_LOCK, ACE_Control_Block >
 ACE_Malloc_T (const ACE_TCHAR *pool_name=0)
 ACE_Malloc_T (const ACE_TCHAR *pool_name, const ACE_TCHAR *lock_name, const ACE_MEM_POOL_OPTIONS *options=0)
 ACE_Malloc_T (const ACE_TCHAR *pool_name, const ACE_MEM_POOL_OPTIONS *options, ACE_LOCK *lock)
 ~ACE_Malloc_T (void)
 Destructor.
int ref_counter (void)
 Get Reference counter.
int release (int close=0)
 Release ref counter.
int remove (void)
 Releases resources allocated by this object.
void * malloc (size_t nbytes)
 Allocate nbytes, but don't give them any initial value.
void * calloc (size_t nbytes, char initial_value= '\0')
 Allocate nbytes, giving them initial_value.
void * calloc (size_t n_elem, size_t elem_size, char initial_value= '\0')
void free (void *ptr)
MEMORY_POOLmemory_pool (void)
 Returns a reference to the underlying memory pool.
int bind (const char *name, void *pointer, int duplicates=0)
int trybind (const char *name, void *&pointer)
int find (const char *name, void *&pointer)
int find (const char *name)
 Returns 0 if name is in the mapping. -1, otherwise.
int unbind (const char *name)
int unbind (const char *name, void *&pointer)
int sync (ssize_t len=-1, int flags=MS_SYNC)
int sync (void *addr, size_t len, int flags=MS_SYNC)
int protect (ssize_t len=-1, int prot=PROT_RDWR)
int protect (void *addr, size_t len, int prot=PROT_RDWR)
ssize_t avail_chunks (size_t size) const
ACE_LOCK & mutex (void)
void dump (void) const
 Dump the state of an object.
void * base_addr (void)
 Return cb_ptr value.
int bad (void)

Additional Inherited Members

- Public Types inherited from ACE_Malloc_T< ACE_MEM_POOL_2, ACE_LOCK, ACE_Control_Block >
typedef ACE_MEM_POOL MEMORY_POOL
typedef ACE_MEM_POOL_OPTIONS MEMORY_POOL_OPTIONS
typedef
ACE_Control_Block::ACE_Name_Node 
NAME_NODE
typedef
ACE_Control_Block::ACE_Malloc_Header 
MALLOC_HEADER
- Public Attributes inherited from ACE_Malloc_T< ACE_MEM_POOL_2, ACE_LOCK, ACE_Control_Block >
 ACE_ALLOC_HOOK_DECLARE
 Declare the dynamic allocation hooks.

Constructor & Destructor Documentation

template<ACE_MEM_POOL_1 , class ACE_LOCK >
ACE_Malloc< ACE_MEM_POOL_1, ACE_LOCK >::ACE_Malloc ( const ACE_TCHAR pool_name = 0)
inline

Initialize ACE_Malloc. This constructor passes pool_name to initialize the memory pool, and uses ACE::basename() to automatically extract out the name used for the underlying lock name (if necessary). Note that pool_name should be located in a directory with the appropriate visibility and protection so that all processes that need to access it can do so.

template<ACE_MEM_POOL_1 , class ACE_LOCK >
ACE_Malloc< ACE_MEM_POOL_1, ACE_LOCK >::ACE_Malloc ( const ACE_TCHAR pool_name,
const ACE_TCHAR lock_name,
const ACE_MEM_POOL_OPTIONS options = 0 
)
inline

Initialize ACE_Malloc. This constructor passes pool_name to initialize the memory pool, and uses lock_name to automatically extract out the name used for the underlying lock name (if necessary). In addition, options is passed through to initialize the underlying memory pool. Note that pool_name should be located in a directory with the appropriate visibility and protection so that all processes that need to access it can do so.


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