This class serves as a Proxy that ensures our process always has the appropriate allocator in place for every operation that accesses or updates the Map Manager. More...
#include <Local_Name_Space_T.h>
Public Member Functions | |
ACE_Name_Space_Map (ALLOCATOR *alloc) | |
Constructor. | |
int | bind (const ACE_NS_String &, const ACE_NS_Internal &, ALLOCATOR *alloc) |
int | unbind (const ACE_NS_String &, ACE_NS_Internal &, ALLOCATOR *alloc) |
int | rebind (const ACE_NS_String &, const ACE_NS_Internal &, ACE_NS_String &, ACE_NS_Internal &, ALLOCATOR *alloc) |
int | find (const ACE_NS_String &, ACE_NS_Internal &, ALLOCATOR *alloc) |
int | close (ALLOCATOR *alloc) |
This class serves as a Proxy that ensures our process always has the appropriate allocator in place for every operation that accesses or updates the Map Manager.
We need this class because otherwise the ALLOCATOR pointer will be stored in the Map_Manager that resides within shared memory. Naturally, this will cause horrible problems since only the first process to set that pointer will be guaranteed the address of the ALLOCATOR is meaningful!
Definition at line 72 of file Local_Name_Space_T.h.
ACE_Name_Space_Map< ALLOCATOR >::ACE_Name_Space_Map | ( | ALLOCATOR * | alloc | ) |
Constructor.
Definition at line 22 of file Local_Name_Space_T.cpp.
: MAP_MANAGER (alloc) { ACE_TRACE ("ACE_Name_Space_Map::ACE_Name_Space_Map"); }
int ACE_Name_Space_Map< ALLOCATOR >::bind | ( | const ACE_NS_String & | ext_id, | |
const ACE_NS_Internal & | int_id, | |||
ALLOCATOR * | alloc | |||
) |
Definition at line 39 of file Local_Name_Space_T.cpp.
{ ACE_TRACE ("ACE_Name_Space_Map::bind"); this->table_allocator_ = alloc; this->entry_allocator_ = alloc; return this->bind_i (ext_id, int_id); }
int ACE_Name_Space_Map< ALLOCATOR >::close | ( | ALLOCATOR * | alloc | ) |
Definition at line 29 of file Local_Name_Space_T.cpp.
{ ACE_TRACE ("ACE_Name_Space_Map::close"); this->table_allocator_ = alloc; this->entry_allocator_ = alloc; return this->close_i (); }
int ACE_Name_Space_Map< ALLOCATOR >::find | ( | const ACE_NS_String & | ext_id, | |
ACE_NS_Internal & | int_id, | |||
ALLOCATOR * | alloc | |||
) |
Definition at line 77 of file Local_Name_Space_T.cpp.
{ ACE_TRACE ("ACE_Name_Space_Map::find"); this->table_allocator_ = alloc; this->entry_allocator_ = alloc; return this->find_i (ext_id, int_id); }
int ACE_Name_Space_Map< ALLOCATOR >::rebind | ( | const ACE_NS_String & | ext_id, | |
const ACE_NS_Internal & | int_id, | |||
ACE_NS_String & | old_ext_id, | |||
ACE_NS_Internal & | old_int_id, | |||
ALLOCATOR * | alloc | |||
) |
Definition at line 63 of file Local_Name_Space_T.cpp.
{ ACE_TRACE ("ACE_Name_Space_Map::rebind"); this->table_allocator_ = alloc; this->entry_allocator_ = alloc; return this->rebind_i (ext_id, int_id, old_ext_id, old_int_id); }
int ACE_Name_Space_Map< ALLOCATOR >::unbind | ( | const ACE_NS_String & | ext_id, | |
ACE_NS_Internal & | int_id, | |||
ALLOCATOR * | alloc | |||
) |
Definition at line 51 of file Local_Name_Space_T.cpp.
{ ACE_TRACE ("ACE_Name_Space_Map::unbind"); this->table_allocator_ = alloc; this->entry_allocator_ = alloc; return this->unbind_i (ext_id, int_id); }