Main Page   Modules   Alphabetical List   Data Structures   File List   Data Fields   Globals  

Module Management

Module management functions. More...


Files

file  IMC.c
 Inter-Module Communication functions.

file  IMC.h
 Inter-Module Communication declarations.

file  ModuleLoader.c
 Module loading functions.

file  Modules.h
 Various module management declarations.


Data Structures

struct  ANetFunctionMap
struct  ANetModuleInfo

Typedefs

typedef ANetFunctionMap ANetFunctionMap
typedef UInt32(* ANetModuleLoadFuncPtr )(ANetModuleInfo *modInfo)
typedef UInt32(* ANetModuleCreateInstanceFuncPtr )(ANetTagID tag, ANetMemoryTag *g)
typedef UInt32(* ANetModuleDestroyInstanceFuncPtr )(ANetMemoryTag g)
typedef UInt32(* ANetClientConnectionMainFuncPtr )(ANetMemoryTag commands, UInt32 nbrPackets, UInt8 *packets, UInt8 **packetIndex)
typedef UInt32(* ANetDataTransMainFuncPtr )(UInt8 dir, UInt32 nbrPackets, UInt8 *packets, UInt8 **packetIndex)
typedef UInt32(* ANetDataTransGetSupportedTagsFuncPtr )(ANetMemoryTag *tagList, ANetMemoryTag *humanReadableList)
typedef UInt32(* ANetClusterGroupMainFuncPtr )(char *name, UInt32 nbrPackets, UInt8 *packets, ANetMemoryTag clusterBuffers)
typedef UInt32(* ANetClusterFilterMainFuncPtr )(UInt32 nbrPackets, UInt8 *packets, ANetMemoryTag packetsToDelete, ANetMemoryTag connectionsToDelete)
typedef UInt32(* ANetClusterFilterForcedFuncPtr )(UInt32 nbrPackets, UInt8 *packets, UInt32 maxBytes, ANetMemoryTag packetsToDelete, ANetMemoryTag connectionsToDelete)
typedef UInt32(* ANetHandshakingProtocolMainFuncPtr )(UInt32 nbrConnections, UInt32 *connectionIDs, ANetMemoryTag *inBuffers, ANetMemoryTag *outBuffers)
typedef UInt32(* ANetPacketProtocolMainFuncPtr )(UInt8 *inAEPs, ANetMemoryTag outAEPs)
typedef UInt32(* ANetPacketProtocolStatusFuncPtr )(UInt32 *status)
typedef UInt32(* ANetConnectionProtocolMainFuncPtr )()
typedef UInt32(* ANetConnectionProtocolStatusFuncPtr )(UInt32 *status)
typedef UInt32(* ANetBandwidthManagerMainFuncPtr )(ANetMemoryTag in, ANetMemoryTag out)
typedef UInt32(* ANetCoreModuleMainFuncPtr )(UInt32 nbrPackets, UInt8 *packets, ANetMemoryTag commands)
typedef UInt32(* ANetStubMainFuncPtr )(UInt32 val)
typedef UInt32(* ANetStubFunc1Ptr )(UInt32 val)
typedef UInt32(* ANetStubFunc2Ptr )(UInt32 val)

Enumerations

enum  {
  kUndefined = 0, kModuleCreateInstance = 1, kModuleDestroyInstance = 2, kClientConnectionMain = 3,
  kDataTransMain = 4, kDataTransGetSupportedTags = 12, kClusterGroupMain = 5, kClusterFilterMain = 6,
  kClusterFilterForced = 13, kHansdhakingProtocolMain = 7, kPacketProtocolMain = 8, kPacketProtocolStatus = 14,
  kConnectionProtocolMain = 9, kConnectionProtocolStatus = 15, kBandwidthManagerMain = 10, kCoreModuleMain = 11,
  kStubMain = 50, kStubFunc1 = 51, kStubFunc2 = 52
}
 Module Function IDs. More...


Functions

UInt32 ANetAddModuleName (ANetModuleInfo *modInfo, char *moduleName)
UInt32 ANetAddFunctionMap (ANetModuleInfo *modInfo, ANetFunctionMap *funcMap)
ANetMemoryTag ANetGetGlobals ()
 Returns the current global tag of the running module. More...

UInt32 CallModuleFunction (char *moduleName, char *instanceName, UInt32 funcID,...)
 Calls a function in a module. More...

void Test ()
void LoadModules ()
void CreateInstance (char *moduleName, char *instanceName)
void LoadInternalModule (ANetModuleLoadFuncPtr func)

Variables

ANetMemoryTag currentGlobals

Detailed Description

Module management functions.

This code manage the different modules running in the ANet daemon.


Typedef Documentation

typedef UInt32(* ANetBandwidthManagerMainFuncPtr)(ANetMemoryTag in, ANetMemoryTag out)
 

Definition at line 121 of file Modules.h.

typedef UInt32(* ANetClientConnectionMainFuncPtr)(ANetMemoryTag commands, UInt32 nbrPackets, UInt8 *packets, UInt8 **packetIndex)
 

Definition at line 86 of file Modules.h.

typedef UInt32(* ANetClusterFilterForcedFuncPtr)(UInt32 nbrPackets, UInt8 *packets, UInt32 maxBytes, ANetMemoryTag packetsToDelete, ANetMemoryTag connectionsToDelete)
 

Definition at line 103 of file Modules.h.

typedef UInt32(* ANetClusterFilterMainFuncPtr)(UInt32 nbrPackets, UInt8 *packets, ANetMemoryTag packetsToDelete, ANetMemoryTag connectionsToDelete)
 

Definition at line 101 of file Modules.h.

typedef UInt32(* ANetClusterGroupMainFuncPtr)(char *name, UInt32 nbrPackets, UInt8 *packets, ANetMemoryTag clusterBuffers)
 

Definition at line 94 of file Modules.h.

typedef UInt32(* ANetConnectionProtocolMainFuncPtr)()
 

Definition at line 115 of file Modules.h.

typedef UInt32(* ANetConnectionProtocolStatusFuncPtr)(UInt32 *status)
 

Definition at line 119 of file Modules.h.

typedef UInt32(* ANetCoreModuleMainFuncPtr)(UInt32 nbrPackets, UInt8 *packets, ANetMemoryTag commands)
 

Definition at line 123 of file Modules.h.

typedef UInt32(* ANetDataTransGetSupportedTagsFuncPtr)(ANetMemoryTag *tagList, ANetMemoryTag *humanReadableList)
 

Definition at line 91 of file Modules.h.

typedef UInt32(* ANetDataTransMainFuncPtr)(UInt8 dir, UInt32 nbrPackets, UInt8 *packets, UInt8 **packetIndex)
 

Definition at line 89 of file Modules.h.

typedef struct ANetFunctionMap ANetFunctionMap
 

typedef UInt32(* ANetHandshakingProtocolMainFuncPtr)(UInt32 nbrConnections, UInt32 *connectionIDs, ANetMemoryTag *inBuffers, ANetMemoryTag *outBuffers)
 

Definition at line 107 of file Modules.h.

typedef UInt32(* ANetModuleCreateInstanceFuncPtr)(ANetTagID tag, ANetMemoryTag *g)
 

Definition at line 83 of file Modules.h.

typedef UInt32(* ANetModuleDestroyInstanceFuncPtr)(ANetMemoryTag g)
 

Definition at line 84 of file Modules.h.

typedef UInt32(* ANetModuleLoadFuncPtr)(ANetModuleInfo *modInfo)
 

Definition at line 77 of file Modules.h.

Referenced by LoadInternalModule().

typedef UInt32(* ANetPacketProtocolMainFuncPtr)(UInt8 *inAEPs, ANetMemoryTag outAEPs)
 

Definition at line 111 of file Modules.h.

typedef UInt32(* ANetPacketProtocolStatusFuncPtr)(UInt32 *status)
 

Definition at line 112 of file Modules.h.

typedef UInt32(* ANetStubFunc1Ptr)(UInt32 val)
 

Definition at line 128 of file Modules.h.

typedef UInt32(* ANetStubFunc2Ptr)(UInt32 val)
 

Definition at line 129 of file Modules.h.

typedef UInt32(* ANetStubMainFuncPtr)(UInt32 val)
 

Definition at line 127 of file Modules.h.


Enumeration Type Documentation

anonymous enum
 

Module Function IDs.

Enumeration values:
kUndefined  void*.
kModuleCreateInstance  ANetModuleCreateInstanceFuncPtr.
kModuleDestroyInstance  ANetModuleDestroyInstanceFuncPtr.
kClientConnectionMain  ANetClientConnectionMainFuncPtr.
kDataTransMain  ANetDataTransMainFuncPtr.
kDataTransGetSupportedTags  ANetDataTransGetSupportedTagsFuncPtr.
kClusterGroupMain  ANetClusterGroupMainFuncPtr.
kClusterFilterMain  ANetClusterFilterMainFuncPtr.
kClusterFilterForced  ANetClusterFilterForcedFuncPtr.
kHansdhakingProtocolMain  ANetHandshakingProtocolMainFuncPtr.
kPacketProtocolMain  ANetPacketProtocolMainFuncPtr.
kPacketProtocolStatus  ANetPacketProtocolStatusFuncPtr.
kConnectionProtocolMain  ANetConnectionProtocolMainFuncPtr.
kConnectionProtocolStatus  ANetConnectionProtocolStatusFuncPtr.
kBandwidthManagerMain  ANetBandwidthManagerMainFuncPtr.
kCoreModuleMain  ANetCoreModuleMainFuncPtr.
kStubMain  ANetStubMainFuncPtr.
kStubFunc1  ANetStubFunc1Ptr.
kStubFunc2  ANetStubFunc2Ptr.

Definition at line 37 of file Modules.h.


Function Documentation

UInt32 ANetAddFunctionMap ANetModuleInfo   modInfo,
ANetFunctionMap   funcMap
 

Definition at line 61 of file ModuleLoader.c.

References kBandwidthManagerMain, kCoreModuleMain, kStubFunc1, kStubFunc2, and kStubMain.

UInt32 ANetAddModuleName ANetModuleInfo   modInfo,
char *    moduleName
 

Definition at line 55 of file ModuleLoader.c.

References kConnectionProtocolMain, kConnectionProtocolStatus, kPacketProtocolMain, and kPacketProtocolStatus.

ANetMemoryTag ANetGetGlobals  
 

Returns the current global tag of the running module.

Definition at line 39 of file IMC.c.

References kClientConnectionMain, kClusterFilterForced, kClusterFilterMain, kClusterGroupMain, kDataTransGetSupportedTags, kDataTransMain, kHansdhakingProtocolMain, kModuleCreateInstance, and kModuleDestroyInstance.

UInt32 CallModuleFunction char *    moduleName,
char *    instanceName,
UInt32    funcID,
...   
 

Calls a function in a module.

Parameters:
moduleName  The name of the module to call
instanceName  The name of the module instance
funcID  The function ID to call
...  Arguments to pass to the function
Returns:
  • 3000: Invalid module name
  • 3001: Invalid instance name
  • 3002: Unknown function ID
  • Otherwise: The returned value of the function
This function calls a function of a module instance.

Definition at line 26 of file IMC.c.

void CreateInstance char *    moduleName,
char *    instanceName
 

Definition at line 42 of file ModuleLoader.c.

Referenced by Test().

void LoadInternalModule ANetModuleLoadFuncPtr    func
 

Definition at line 49 of file ModuleLoader.c.

References ANetModuleLoadFuncPtr.

Referenced by LoadModules().

void LoadModules  
 

Definition at line 37 of file ModuleLoader.c.

References LoadInternalModule().

Referenced by Test().

void Test  
 

Definition at line 29 of file ModuleLoader.c.

References CallModuleFunction(), CreateInstance(), kStubMain, and LoadModules().


Variable Documentation

ANetMemoryTag currentGlobals
 

Definition at line 24 of file IMC.c.

Referenced by ANetGetGlobals().


Generated on Sun Dec 23 15:21:00 2001 for ANet by doxygen 1.2.12 written by Dimitri van Heesch, © 1997-2001

SourceForge
Logo