dcrud  0.0.0
Distributed data and services
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros
IParticipant.h File Reference
#include <io/InetSocketAddress.h>
#include "ICache.h"
#include "IDispatcher.h"
#include "IRegistry.h"
Include dependency graph for IParticipant.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  dcrudLocalFactory_s
 
struct  dcrudRemoteFactory_s
 

Typedefs

typedef dcrudShareable(* dcrudShareableFactory )()
 
typedef void(* dcrudLocalFactory_Set )(dcrudShareableData This, const dcrudShareableData source)
 
typedef ioStatus(* dcrudLocalFactory_Serialize )(dcrudShareableData This, ioByteBuffer target)
 
typedef ioStatus(* dcrudLocalFactory_Unserialize )(dcrudShareableData This, ioByteBuffer source)
 
typedef bool(* dcrudLocalFactory_Initialize )(dcrudShareableData This)
 
typedef void(* dcrudRemoteFactory_create )(struct dcrudRemoteFactory_s *This, dcrudArguments how)
 
typedef void(* dcrudRemoteFactory_update )(struct dcrudRemoteFactory_s *This, dcrudShareable what, dcrudArguments how)
 
typedef void(* dcrudRemoteFactory_delete )(struct dcrudRemoteFactory_s *This, dcrudShareable what)
 
typedef struct dcrudLocalFactory_s dcrudLocalFactory
 
typedef struct dcrudRemoteFactory_s dcrudRemoteFactory
 

Functions

 UTIL_ADT (dcrudIParticipant)
 
void dcrudIParticipant_listen (dcrudIParticipant This, dcrudIRegistry registry, const char *intrfc, bool dumpReceivedBuffer)
 
bool dcrudIParticipant_registerLocalFactory (dcrudIParticipant This, dcrudLocalFactory *local)
 
bool dcrudIParticipant_registerRemoteFactory (dcrudIParticipant This, dcrudRemoteFactory *remote)
 
dcrudICache dcrudIParticipant_getDefaultCache (dcrudIParticipant This)
 
dcrudStatus dcrudIParticipant_createCache (dcrudIParticipant This, dcrudICache *target, byte *cacheId)
 
dcrudICache dcrudIParticipant_getCache (dcrudIParticipant This, byte ID)
 
dcrudIDispatcher dcrudIParticipant_getDispatcher (dcrudIParticipant This)
 
dcrudShareable dcrudIParticipant_createShareable (dcrudIParticipant This, dcrudClassID classID)
 
void dcrudIParticipant_run (dcrudIParticipant This)
 

Typedef Documentation

typedef bool(* dcrudLocalFactory_Initialize)(dcrudShareableData This)

Definition at line 18 of file IParticipant.h.

typedef ioStatus(* dcrudLocalFactory_Serialize)(dcrudShareableData This, ioByteBuffer target)

Definition at line 16 of file IParticipant.h.

typedef void(* dcrudLocalFactory_Set)(dcrudShareableData This, const dcrudShareableData source)

Definition at line 15 of file IParticipant.h.

typedef ioStatus(* dcrudLocalFactory_Unserialize)(dcrudShareableData This, ioByteBuffer source)

Definition at line 17 of file IParticipant.h.

typedef void(* dcrudRemoteFactory_create)(struct dcrudRemoteFactory_s *This, dcrudArguments how)

Definition at line 20 of file IParticipant.h.

typedef void(* dcrudRemoteFactory_delete)(struct dcrudRemoteFactory_s *This, dcrudShareable what)

Definition at line 22 of file IParticipant.h.

typedef void(* dcrudRemoteFactory_update)(struct dcrudRemoteFactory_s *This, dcrudShareable what, dcrudArguments how)

Definition at line 21 of file IParticipant.h.

typedef dcrudShareable(* dcrudShareableFactory)()

Definition at line 11 of file IParticipant.h.

Function Documentation

dcrudStatus dcrudIParticipant_createCache ( dcrudIParticipant  This,
dcrudICache *  target,
byte cacheId 
)
dcrudShareable dcrudIParticipant_createShareable ( dcrudIParticipant  This,
dcrudClassID  classID 
)
dcrudICache dcrudIParticipant_getCache ( dcrudIParticipant  This,
byte  ID 
)
dcrudICache dcrudIParticipant_getDefaultCache ( dcrudIParticipant  This)
dcrudIDispatcher dcrudIParticipant_getDispatcher ( dcrudIParticipant  This)
void dcrudIParticipant_listen ( dcrudIParticipant  This,
dcrudIRegistry  registry,
const char *  intrfc,
bool  dumpReceivedBuffer 
)

Use the registry to instanciate and listen to other participants.

Parameters
Thisthis participant
registrythe registry to use
intrfcthe network interface to use, identified by its IP address, may be null, in such case the first up, non loopback, multicast capable interface will be used
dumpReceivedBufferif true, dump the received frames on stderr
bool dcrudIParticipant_registerLocalFactory ( dcrudIParticipant  This,
dcrudLocalFactory local 
)
bool dcrudIParticipant_registerRemoteFactory ( dcrudIParticipant  This,
dcrudRemoteFactory remote 
)
void dcrudIParticipant_run ( dcrudIParticipant  This)
UTIL_ADT ( dcrudIParticipant  )