FBB::SharedSegment

libbobcat-dev_3.22.00-x.tar.gz

2005-2014


FBB::SharedSegment(3bobcat)

FBB::SharedSegment(3bobcat)

libbobcat-dev_3.22.00-x.tar.gz Shared Memory Data

2005-2014

NAME

FBB::SharedSegment - Shared Memory data structure

SYNOPSIS

#include <bobcat/sharedsegment>
Linking option: -lbobcat

DESCRIPTION

The class FBB::SharedSegment implements the shared memory data structure which is used by Bobcat's shared memory classes. Bobcat's SharedMemory class accesses or defines a shared memory segment which is interpreted as an FBB::SharedSegment object. The total amount of requested shared memory is always a lower bound to the actual amount of shared memory that eventually may become available. As a fictitious example: assume 100 kB of memory is requested, then the FBB::SharedSegment object, maintains a table of, e.g., 10 entries, each controlling the access to a shared memory block of 10 kB. These 10 kB blocks aren't immediately allocated, but become available once the program reads from or writes to addresses located in these data segments.

The class FBB::SharedSegment therefore defines a gateway, controlling access to and allocating the shared memory data segment. The mentioned table consists of nBlocks SharedBlock (sharedblock(3bobcat)) values, offering mutexes and IDs of shared data segments. As always, the mutexes control which process has access to a particular block of shared data memory, and the IDs are either -1, meaning that their shared memory data segments has as not yet been defined, or they contain the IDs of defined shared memory data segments.

The class FBB::SharedSegment's sole responsibility is to offer the framework as described. When used by a FBB::SharedMemory object different processes may gain access to different parts of the shared memory data without interfering each other's read and write actions.

NAMESPACE

FBB
All constructors, members, operators and manipulators, mentioned in this man-page, are defined in the namespace FBB.

INHERITS FROM

-

CONSTRUCTORS

No publicly accessible constructors have been defined for FBB::SharedSegment. A static member function create (see below) is available, returning a pointer to a shared memory segment, in which a FBB::SharedSegment has been defined.

OVERLOADED OPERATORS

Overloaded move and copy assignment operators are not available.

MEMBER FUNCTIONS

STATIC MEMBER FUNCTIONS

EXAMPLE

See the sharedstream(3bobcat) man page.

FILES

bobcat/sharedsegment - defines the class interface

SEE ALSO

bobcat(7), chmod(1), isharedstream(3bobcat), osharedstream(3bobcat), sharedblock(3bobcat), sharedmemory(3bobcat), sharedmutex(3bobcat), sharedpos(3bobcat), sharedstream(3bobcat), sharedstreambuf(3bobcat)

BUGS

None Reported.

DISTRIBUTION FILES

BOBCAT

Bobcat is an acronym of `Brokken's Own Base Classes And Templates'.

COPYRIGHT

This is free software, distributed under the terms of the GNU General Public License (GPL).

AUTHOR

Frank B. Brokken (f.b.brokken@rug.nl).