Main Page   Compound List   File List   Compound Members   File Members  

lib/gobj/server.h File Reference

Gobj server header. More...

#include <gobjconfig.h>
#include <gobj/decls.h>
#include <gobj/container.h>

Functions

void Gj_server_new (Gj_Ctx* ctx)
 Create a new server.

int Gj_server_restore (Gj_Ctx* ctx, Gj_ContainerId id)
 Restore the server from a container. More...

void Gj_server_delete (Gj_Ctx* ctx)
 Delete the server.

int Gj_server_save (Gj_Ctx* ctx, Gj_ContainerId id)
 Save the server to a container. More...

int Gj_server_readIfaces (Gj_Ctx* ctx, Gj_Stream* stream)
 Read the interfaces from a stream. More...

int Gj_server_writeIfaces (Gj_Ctx* ctx, Gj_Stream* stream)
 Write the interfaces to a stream. More...

int Gj_server_start (Gj_Ctx* ctx)
 Start the server. More...

void Gj_server_stop (Gj_Ctx* ctx)
 Stop the server.

int Gj_server_addIface (Gj_Ctx* ctx, Gj_Id* iface)
 Add an interface to the server. More...

int Gj_server_removeIface (Gj_Ctx* ctx, Gj_Id* iface)
 Remove an interface from the server. More...

int gj_server_serve (Gj_Ctx* ctx, Gj_Stream* stream)
 The main server serving routine. More...


Detailed Description

Gobj server header.


Function Documentation

int Gj_server_restore ( Gj_Ctx * ctx,
Gj_ContainerId id )
 

Restore the server from a container.

Returns:
0 on success, -1 otherwise

int Gj_server_save ( Gj_Ctx * ctx,
Gj_ContainerId id )
 

Save the server to a container.

Returns:
0 on success, -1 otherwise.

int Gj_server_readIfaces ( Gj_Ctx * ctx,
Gj_Stream * stream )
 

Read the interfaces from a stream.

Returns:
0 on success, -1 otherwise.

int Gj_server_writeIfaces ( Gj_Ctx * ctx,
Gj_Stream * stream )
 

Write the interfaces to a stream.

Returns:
0 on success, -1 otherwise.

int Gj_server_start ( Gj_Ctx * ctx )
 

Start the server.

Returns:
0 on success, -1 otherwise.

int Gj_server_addIface ( Gj_Ctx * ctx,
Gj_Id * iface )
 

Add an interface to the server.

Returns:
0 on success, -1 otherwise.

int Gj_server_removeIface ( Gj_Ctx * ctx,
Gj_Id * iface )
 

Remove an interface from the server.

If the server is running, it is stopped and then restarted.

Returns:
0 on success, -1 otherwise.

int gj_server_serve ( Gj_Ctx * ctx,
Gj_Stream * stream )
 

The main server serving routine.

The stream must be DELETED by this function in any case.

Returns:
0 on success, -1 otherwise.

For internal use only.


Generated at Fri Aug 17 18:28:57 2001 for Gobj by doxygen1.2.1 written by Dimitri van Heesch, © 1997-2000