The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

IPC::Shm::Segment

SYNOPSIS

This class is part of the IPC::Shm implementation. You should probably not be using it directly.

CONSTRUCTORS

$class->named( $varname )

Attach to a named variable's segment, creating if necessary. The contents of the varname string are just how the variable is typed in perl code.

$class->anonymous

Create a new anonymous segment.

$class->anonymous( $cookie )

Attach to an existing anonymous segment using a cookie value. Those cookies might be retrieved with the varanon method, or might be stored in a standin. See below.

ATTRIBUTES

$this->varname

Returns the variable's name, if any.

$this->varname( $varname );

Sets the variable's name.

$this->varanon

Returns the anonymous variable identifier cookie, if any.

$this->varanon( $cookie )

Sets the anonymous variable identifier cookie.

$this->vartype

Returns 'HASH', 'ARRAY', or 'SCALAR'.

$this->vartype( $vartype )

Stores the variable type. Only meaningful for anonymous segments.

$this->varid

Retrieves a human-redable string identifying the variable.

OVERRIDDES

$this->remove

Overridden from IPC::Shm::Simple to remove table entries for named variables.

$this->DETACH

Called by IPC::Shm::Simple when the last in-process instance is being DESTROYed.

STAND-IN REFERENCES

$this->standin

This is a shared memory analogue of a reference. It is stored in the shared memory variable that holds the reference.

Returns a reference to an anonymous hash containing suitable identifiers.

$class->standin_type( $standin )

Returns the variable type that the standin points to.

$class->standin_shmid( $standin )

Returns the shmid where the standin points to.

$class->standin_restand( $standin )

Returns the original object that generated the standin, or an exactly equal copy of that object.

$class->standin_discard( $standin )

Indicates that the standin reference is going away.

Returns the original object as standin_restand.

AUTHOR

Kevin Cody-Little <kcody@cpan.org>