#include <RIPCSharedMemory.h>
Inheritance diagram for RIPCSharedMemory:
Public Types | |
enum | RIPCPrimitiveType { RIPC_MUTEX, RIPC_EVENT, RIPC_SEMAPHORE, RIPC_BARRIER, RIPC_LOCK, RIPC_SHARED_MEMORY, RIPC_QUEUE } |
enum | RIPCRanks { DEFAULT_RANK = 0 } |
Public Member Functions | |
virtual void | set (RIPCObject const &objDesc)=0 |
virtual void | set (void const *obj, size_t objSize)=0 |
virtual void | get (RIPCObject &objDesc)=0 |
void * | get () |
RIPCPrimitiveType | getType () |
char const * | getTypeName () |
virtual char const * | getName ()=0 |
virtual bool | alreadyExists ()=0 |
void | waitFor () |
bool | waitFor (unsigned timeout) |
virtual void | priorityWait (int rank)=0 |
virtual bool | priorityWait (int rank, unsigned timeout)=0 |
virtual void | reset ()=0 |
virtual void | close ()=0 |
virtual void * | allocate (size_t size) |
virtual void | deallocate (void *obj, size_t size=0) |
Static Public Member Functions | |
void | deallocator (RIPCObject const &objDesc) |
set
method by some other session. Then it should call get
method to get the most recent version of the object. If client prefer to receive updates asynchronously, it should lanunch separate thread which will preform wait in loop for updates of this object, thne get the most recent version of the object and somehow notify other threads that object is changed.
Semantic of methods inherited from RIPCPrimitive
:
waitFor
set
method is invoked. For remote sessions, sequence number of the object is remembered by local stub and is sent to the server to be compared with sequence number of shared memory object at the server. reset
|
Primitive types |
|
Method for allocation memory for container elements (currently queue and shared memory). This method can be overriden by derived class* to provide custom allocation policy. |
|
Primitive returned by
|
|
Close primitive. This method decrease access counter of the primitive and once it becomes zero, primitive is destroyed. |
|
Method for deallocation memory for container elements (currently queue and shared memory). This method can be overriden by derived class to provide custom allocation policy. |
|
Get the most recent version of shared memory object. Object is created by means of
|
|
Get the most recent version of shared memory object. If
|
|
Get primitive name. Name of the primitive is unique with primitives of the same type (events, semaphores,...). It is possible that, for example, event and mutex has the same name.
|
|
Get RIPC primitive type
Implements RIPCPrimitive. |
|
Get RIPC primitive type name
|
|
Priority wait until state of primitive is switched with timeout. Requests with the lowest
|
|
Priority wait until state of primitive is switched. Requests with the lowest
|
|
Reset primitive. Semantic of this method depends on particular primitive type and is explained in specification of each primitive. |
|
Make new object visible to all other sessions using this shared memory object
|
|
Make new object visible to all other sessions using this shared memory object
|
|
Wait until state of primitive is switched with timeout. Semantic of this method depends on particular primitive type and is explained in specification of each primitive.
|
|
Wait until state of primitive is switched. Semantic of this method depends on particular primitive type and is explained in specification of each primitive. |