bonobo-context

bonobo-context

Name

bonobo-context -- Extensible runtime service interface

Description

The bonobo-context code is designed to provide a way to expose CORBA contexts through a single C interface. This is so that language bindings can get away with wrapping a single function, and yet have access to the whole Bonobo service framework. Two examples of this are the MonikerContext and the RunningContext ( see Bonobo_Context.idl ).

The list of contexts is open and may be expanded in the future, currently there are the following:

  • Activation - Bonobo/MonikerContext

  • Running - Bonobo/RunningContext

The running context is particularly useful for ensuring that server processes exit cleanly when all their objects and derived objects are dead. To do this we can simply do the following:

Since this is a commonly used thing there is a helper to make this easier:

Details

bonobo_context_get ()

Bonobo_Unknown bonobo_context_get           (const CORBA_char *context_name,
                                             CORBA_Environment *opt_ev);

The most useful context is named 'Activation' and returns the IDL:Bonobo/ActivationContext:1.0 interface.


bonobo_context_add ()

void        bonobo_context_add              (const CORBA_char *context_name,
                                             Bonobo_Unknown context);

This function adds a new context to the context system


bonobo_context_running_get ()

BonoboObject* bonobo_context_running_get    (void);


bonobo_running_context_auto_exit_unref ()

void        bonobo_running_context_auto_exit_unref
                                            (BonoboObject *object);