## NAME

ACE_Name_Space_Map - 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.

## SYNOPSIS

    #include <ACE/Local_Name_Space_T.h>

    template<class ALLOCATOR>
    class ACE_Name_Space_Map : public MAP_MANAGER
    {
      public:
        ACE_Name_Space_Map (ALLOCATOR *alloc);
        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);
    };

## DESCRIPTION

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!

## The following methods are Proxies to the underlying methods

provided by `ACE_Hash_Map_Manager`. When they are called, they acquire the lock, set the allocator to the one specific to this process, and then call down to perform the intended operation.

    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);

## AUTHOR

Prashant Jain (pjain@cs.wustl.edu), Irfan Pyarali (irfan@wuerl.wustl.edu), and Douglas C. Schmidt (schmidt@cs.wustl.edu).

## LIBRARY

ACE