TABLE OF CONTENTS


libram-rpc/libram-rpcserver [ Generics ]

[ Top ] [ libram-rpc ] [ Generics ]

NAME

libram-rpcserver - server library for libram-rpc calls

SYNOPSIS

#include <libram-xdr.h>
#include <libram.h>
#include <libram-rpcserver.h>

DESCRIPTION

libram-rpcserver is the server side library for implementing analysis and modification with onc/rpc.

The library is initialized with libramrpcserver_init(3). libramrpcserver_init(3) registers the callbacks to be called.

libram-rpcserver implements its own event loop with libramrpcserver_loop(3). But if the analysis component implements its own event loop, libram-rpcserver(3) can be embedded in this event loopt with two functions:

See libramrpcserver_loop(3) for further details.

SEE ALSO

libram(3), libramrpcserver_init(3), libramrpcserver_exit(3), libramrpcserver_fdset(3), libramrpcserver_process(3), libramrpcserver_loop(3), libramrpcserver_callbacks(3), libramrpcserver_reply(3)


libram-rpc/libramrpcserver_callbacks [ Generics ]

[ Top ] [ libram-rpc ] [ Generics ]

NAME

libramrpcserver_callbacks - callbacks for libram-rpcserver calls

DESCRIPTION

This callback defines the routines that get called when the corresponding rpc functions are called. They are activated by the libramrpcserver_process(3) functions.

The callbacks are registered using the libramrpcserver_init(3) function.

The callbacks are divided into two groups. The first group is the client callbacks that get called when a client connects to or disconnects from the libram-rpcserver. These callbacks are the c_connect an c_disconnect callbacks.

The second group is the data callbacks that get called when a new data session is detected, when data is passed and when the session is closed. These callbacks are the c_open, c_data, and c_close callbacks.

The data callbacks return a reply structure of the analysis result. If the result is not yet available, the callbacks return NULL. To send the result once it is available, the analysis component can use libramrpcserver_reply(3) to pass the result to the client.

SOURCE

struct libramrpcserver_callbacks {
        reply* (*c_open)(long, long, int, conn_hdr*, conn_payload*, caddr_t);
        reply* (*c_data)(long, long, int, conn_payload*, caddr_t);
        reply* (*c_close)(long, long, int, conn_payload*, caddr_t);
        void   (*c_connect)(int, caddr_t);
        void   (*c_disconnect)(int, caddr_t);
        caddr_t c_priv;
};

ATTRIBUTES

SEE ALSO

libram(3), libramrpcserver_init(3), libramrpcserver_process(3), libramrpcserver_reply(3)


libram/libramrpcserver_config_detail [ Structures ]

[ Top ] [ libram ] [ Structures ]

NAME

libramrpcserver_config_detail

DESCRIPTION

This enum defines the possible information that libramrpcserver_config(3) can return.

SOURCE

enum libramrpcserver_config_detail {
    LIBRAMRPCSERVER_NAME,
    LIBRAMRPCSERVER_VERSION,
    LIBRAMRPCSERVER_STRING,
    LIBRAMRPCSERVER_CONFIGURE,
    LIBRAMRPCSERVER_BUGREPORT,
};

SEE ALSO

libram-rpcserver(3), libramrpcserver_config(3), libramrpcserver_printconfig(3)