<!-- ##### SECTION Title ##### -->

MateConf CORBA

<!-- ##### SECTION Short_Description ##### -->

Interface for setting up CORBA

<!-- ##### SECTION Long_Description ##### -->
<para>
MateConf needs a connection to an ORB; it needs to be able to receive
CORBA requests and act on them; and it needs CORBA connection
authentication. There are two basic ways to do this; first, you 
can let MateConf set things up by calling mateconf_init_orb(); second, you
can set things up yourself (or let MATE set things up), then call
mateconf_set_orb() to tell the MateConf library about it.
</para>

<para>
The problem right now is that <application>mateconfd</application> only
speaks the authentication mechanism from mateconf_init_orb(), since the 
MATE authentication mechanism requires an X server connection. So 
right now if you use mate_CORBA_init() then you can't talk to
<application>mateconfd</application>. (If you use mateconf_init_orb() in an
otherwise non-CORBA MATE application then you can.) This will get
fixed by the time MATE 2.0 is ready.
</para>

<!-- ##### SECTION See_Also ##### -->
<para>

</para>

<!-- ##### FUNCTION mateconf_init_orb ##### -->
<para>
Initializes CORBA and a connection to the ORB, sets up authentication, 
and adds CORBA-related event handlers to your application's event
loop. Your application must be using the event loop from GLib; this is
the event loop all GTK+ applications use, but it also works in
non-GTK+ applications (such as <application>mateconfd</application>, if
you're looking for some sample code).
</para>

<para>
mateconf_init_orb() wants to see the command line arguments to check for
MateCORBA options. If it finds MateCORBA options it will remove them from @argc
and @argv. It returns an error if CORBA initialization failes.
</para>

@argc: address of argc.
@argv: argv.
@err: the return location for an allocated #GError, or <symbol>NULL</symbol> to ignore errors.
@Returns: the ORB object reference.


<!-- ##### FUNCTION mateconf_set_orb ##### -->
<para>
mateconf_set_orb() allows you to tell MateConf about an ORB obtained by
means other than mateconf_init_orb(). You should call mateconf_init_orb()
<emphasis>or</emphasis> this function, never both.
</para>

@orb: the ORB MateConf should use to communicate with <application>mateconfd</application>.


<!-- ##### FUNCTION mateconf_get_orb ##### -->
<para>
Returns the ORB MateConf is using.
</para>

@Returns: the ORB MateConf is using.


