NAME

        Tie::Win32MemMap - TieHash functionality for Win32-MemMap


REQUIREMENTS

        Win32-MemMap http://wwws01.valero.com/perl/packages
        Storable


SYNOPSIS

        use Tie::Win32MemMap;
        tie(%h, 'Tie::Win32MemMap', { Create => MEM_NEW_SHARE, MapName => 'Test', Size => 100000 });


DESCRIPTION

This TIEHASH package will tie a hash structure to a shared memory space on Windows NT. This allows Perl applications to communicate any kind of data between themselves using the fastest method possible.


CONSTANTS

        MEM_NEW_SHARE
        MEM_VIEW_SHARE


CONSTRUCTOR

        tie %h, 'Tie::Win32MemMap', { Create => 1|0 [,MapName => $name [,Size => $size]] }

Arguements are passed as an anonymous hash. The only required arguement is Create.

Create: If set to true, a new memory share is created in memory, otherwise an attempt to map a 'View' to an existing share (created by another process) is made. See CONSTANTS.

MapName: The name used to identify the memory share. If not provided, the name 'Default' is used.

Size: The size in bytes to be allocated for the memory share. If not provided, a default size of 100,000 bytes will be allocated. This arguement is ignored for 'Views'.


EXAMPLES

        # Parent.pl
        use Tie::Win32MemMap;
        tie(%h, 'Tie::Win32MemMap', { Create => MEM_NEW_SHARE, MapName => 'Test', Size => 10000 });
        $h{key}  = [qw(apple bananna orange)];
        $h{key2} = "this is my string\n";
        while (1) { sleep 1 }
        __END__
        
        # Child.pl
        use Tie::Win32MemMap;
        tie(%h, 'Tie::Win32MemMap', { Create => MEM_VIEW_SHARE, MapName => 'Test' });
        print $h{key}->[1], "\n";
        print $h{key2}, "\n";
        __END__


VERSION

        03/27/2000 - Version 1.02


AUTHOR

        Grant Hopwood
        hopwoodg@valero.com


COPYRIGHT

        Hack n' slash babee.
        
        Win32::MemMap is copyright Amine Moulay Ramdane (aminer@generation.net).