|
|
|
|
Documentation |
|
Main Page Namespace List Class Hierarchy Alphabetical List Compound List File List Namespace Members Compound Members File Members Related Pages Search
NLMISC::CSharedMemory Class ReferenceEncapsulation of shared memory APIs.
More...
#include <shared_memory.h>
List of all members.
Detailed Description
Encapsulation of shared memory APIs.
Using file mapping under Windows, System V shared memory (shm) under Linux.
Note: under Linux, an option could be added to prevent a segment to be swapped out.
-
Author:
-
Olivier Cado , Nevrax France
-
Date:
-
2002
Definition at line 68 of file shared_memory.h.
Member Function Documentation
void * NLMISC::CSharedMemory::accessSharedMemory |
( |
TSharedMemId |
sharedMemId |
) |
[static] |
|
|
Get access to an existing shared memory segment.
The id must be used. -
Returns:
-
Access address of the segment. Its size was determined at the creation.
Definition at line 90 of file shared_memory.cpp.
References NLMISC::TSharedMemId. |
bool NLMISC::CSharedMemory::closeSharedMemory |
( |
void * |
accessAddress |
) |
[static] |
|
void * NLMISC::CSharedMemory::createSharedMemory |
( |
TSharedMemId |
sharedMemId, |
|
|
uint32 |
size |
|
) |
[static] |
|
void NLMISC::CSharedMemory::destroySharedMemory |
( |
TSharedMemId |
sharedMemId, |
|
|
bool |
force = false |
|
) |
[static] |
|
|
Destroy a shared memory segment (must be call by the process that created the segment, not by the accessors).
"Rescue feature": set "force" to true if a segment was created and left out of control (meaning a new createSharedMemory() with the same sharedMemId fails), but before, make sure the segment really belongs to you!
Note: this method does nothing under Windows, destroying is automatic.
Definition at line 159 of file shared_memory.cpp.
References NLMISC::SharedMemIdsToShmids, and NLMISC::TSharedMemId. |
The documentation for this class was generated from the following files:
|
|