This file is indexed.

/usr/share/gtk-doc/html/bonobo-activation/bonobo-activation-Registration.html is in libbonobo2-dev 2.32.1-0ubuntu1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Registration</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.75.2">
<link rel="home" href="index.html" title="Bonobo Activation API Reference Manual">
<link rel="up" href="api-reference.html" title="API Reference">
<link rel="prev" href="bonobo-activation-Utilities.html" title="Utilities">
<link rel="next" href="bonobo-activation-Debugging.html" title="Debugging">
<meta name="generator" content="GTK-Doc V1.16 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
<tr valign="middle">
<td><a accesskey="p" href="bonobo-activation-Utilities.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
<td><a accesskey="u" href="api-reference.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
<th width="100%" align="center">Bonobo Activation API Reference Manual</th>
<td><a accesskey="n" href="bonobo-activation-Debugging.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
</tr>
<tr><td colspan="5" class="shortcuts">
<a href="#bonobo-activation-Registration.synopsis" class="shortcut">Top</a>
                   | 
                  <a href="#bonobo-activation-Registration.description" class="shortcut">Description</a>
</td></tr>
</table>
<div class="refentry">
<a name="bonobo-activation-Registration"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle"><a name="bonobo-activation-Registration.top_of_page"></a>Registration</span></h2>
<p>Registration — Registering CORBA objects to Bonobo Activation.</p>
</td>
<td valign="top" align="right"></td>
</tr></table></div>
<div class="refsynopsisdiv">
<a name="bonobo-activation-Registration.synopsis"></a><h2>Synopsis</h2>
<pre class="synopsis">
#include &lt;bonobo-activation/bonobo-activation.h&gt;

enum                <a class="link" href="bonobo-activation-Registration.html#Bonobo-RegistrationResult" title="enum Bonobo_RegistrationResult">Bonobo_RegistrationResult</a>;
<span class="returnvalue">void</span>                <a class="link" href="bonobo-activation-Registration.html#bonobo-activation-unregister-active-server" title="bonobo_activation_unregister_active_server ()">bonobo_activation_unregister_active_server</a>
                                                        (<em class="parameter"><code>const <span class="type">char</span> *iid</code></em>,
                                                         <em class="parameter"><code><span class="type">CORBA_Object</span> obj</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="bonobo-activation-Registration.html#bonobo-activation-registration-env-free" title="bonobo_activation_registration_env_free ()">bonobo_activation_registration_env_free</a>
                                                        (<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Singly-Linked-Lists.html#GSList"><span class="type">GSList</span></a> *reg_env</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Singly-Linked-Lists.html#GSList"><span class="returnvalue">GSList</span></a> *            <a class="link" href="bonobo-activation-Registration.html#bonobo-activation-registration-env-set" title="bonobo_activation_registration_env_set ()">bonobo_activation_registration_env_set</a>
                                                        (<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Singly-Linked-Lists.html#GSList"><span class="type">GSList</span></a> *reg_env</code></em>,
                                                         <em class="parameter"><code>const <span class="type">char</span> *name</code></em>,
                                                         <em class="parameter"><code>const <span class="type">char</span> *value</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="bonobo-activation-Registration.html#bonobo-activation-registration-env-set-global" title="bonobo_activation_registration_env_set_global ()">bonobo_activation_registration_env_set_global</a>
                                                        (<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Singly-Linked-Lists.html#GSList"><span class="type">GSList</span></a> *reg_env</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> append_if_existing</code></em>);
<a class="link" href="bonobo-activation-Registration.html#Bonobo-RegistrationResult" title="enum Bonobo_RegistrationResult"><span class="returnvalue">Bonobo_RegistrationResult</span></a>  <a class="link" href="bonobo-activation-Registration.html#bonobo-activation-register-active-server" title="bonobo_activation_register_active_server ()">bonobo_activation_register_active_server</a>
                                                        (<em class="parameter"><code>const <span class="type">char</span> *iid</code></em>,
                                                         <em class="parameter"><code><span class="type">CORBA_Object</span> obj</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Singly-Linked-Lists.html#GSList"><span class="type">GSList</span></a> *reg_env</code></em>);
const <span class="returnvalue">char</span> *        <a class="link" href="bonobo-activation-Registration.html#bonobo-activation-iid-get" title="bonobo_activation_iid_get ()">bonobo_activation_iid_get</a>           (<em class="parameter"><code><span class="type">void</span></code></em>);
                    <a class="link" href="bonobo-activation-Registration.html#BonoboActivationPlugin" title="BonoboActivationPlugin">BonoboActivationPlugin</a>;
                    <a class="link" href="bonobo-activation-Registration.html#BonoboActivationPluginObject" title="BonoboActivationPluginObject">BonoboActivationPluginObject</a>;
<span class="returnvalue">void</span>                <a class="link" href="bonobo-activation-Registration.html#bonobo-activation-plugin-use" title="bonobo_activation_plugin_use ()">bonobo_activation_plugin_use</a>        (<em class="parameter"><code><span class="type">PortableServer_Servant</span> servant</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> impl_ptr</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="bonobo-activation-Registration.html#bonobo-activation-plugin-unuse" title="bonobo_activation_plugin_unuse ()">bonobo_activation_plugin_unuse</a>      (<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> impl_ptr</code></em>);
</pre>
</div>
<div class="refsect1">
<a name="bonobo-activation-Registration.description"></a><h2>Description</h2>
<p>
When writing a component which can be activated through
Bonobo Activation by clients, you need to be register your component
to Bonobo Activation once it is created.
</p>
</div>
<div class="refsect1">
<a name="bonobo-activation-Registration.details"></a><h2>Details</h2>
<div class="refsect2">
<a name="Bonobo-RegistrationResult"></a><h3>enum Bonobo_RegistrationResult</h3>
<pre class="programlisting">typedef enum {
  Bonobo_ACTIVATION_REG_SUCCESS,
  Bonobo_ACTIVATION_REG_NOT_LISTED,
  Bonobo_ACTIVATION_REG_ALREADY_ACTIVE,
  Bonobo_ACTIVATION_REG_ERROR
} Bonobo_RegistrationResult;
</pre>
<p>
</p>
</div>
<hr>
<div class="refsect2">
<a name="bonobo-activation-unregister-active-server"></a><h3>bonobo_activation_unregister_active_server ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                bonobo_activation_unregister_active_server
                                                        (<em class="parameter"><code>const <span class="type">char</span> *iid</code></em>,
                                                         <em class="parameter"><code><span class="type">CORBA_Object</span> obj</code></em>);</pre>
<p>
Unregisters <em class="parameter"><code>obj</code></em> with <em class="parameter"><code>iid</code></em> with the local bonobo-activation-server
daemon.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>iid</code></em> :</span></p></td>
<td>IID of the server to unregister.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>obj</code></em> :</span></p></td>
<td>CORBA::Object to unregister.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="bonobo-activation-registration-env-free"></a><h3>bonobo_activation_registration_env_free ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                bonobo_activation_registration_env_free
                                                        (<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Singly-Linked-Lists.html#GSList"><span class="type">GSList</span></a> *reg_env</code></em>);</pre>
<p>
Frees the registration environment list, <em class="parameter"><code>reg_env</code></em>.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><em class="parameter"><code>reg_env</code></em> :</span></p></td>
<td>a GSList pointer.</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="bonobo-activation-registration-env-set"></a><h3>bonobo_activation_registration_env_set ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Singly-Linked-Lists.html#GSList"><span class="returnvalue">GSList</span></a> *            bonobo_activation_registration_env_set
                                                        (<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Singly-Linked-Lists.html#GSList"><span class="type">GSList</span></a> *reg_env</code></em>,
                                                         <em class="parameter"><code>const <span class="type">char</span> *name</code></em>,
                                                         <em class="parameter"><code>const <span class="type">char</span> *value</code></em>);</pre>
<p>
Sets the environment variable <em class="parameter"><code>name</code></em> to <em class="parameter"><code>value</code></em> in the
registration environment list <em class="parameter"><code>reg_env</code></em>.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>reg_env</code></em> :</span></p></td>
<td>a GSList pointer.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>name</code></em> :</span></p></td>
<td>the name of the env variable (must not be <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>).</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>value</code></em> :</span></p></td>
<td>the value of the env variable (may be <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>).</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>the new start of <em class="parameter"><code>reg_env</code></em>.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="bonobo-activation-registration-env-set-global"></a><h3>bonobo_activation_registration_env_set_global ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                bonobo_activation_registration_env_set_global
                                                        (<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Singly-Linked-Lists.html#GSList"><span class="type">GSList</span></a> *reg_env</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> append_if_existing</code></em>);</pre>
<p>
Sets the global registration environment list with the
contents of <em class="parameter"><code>reg_env</code></em>. If <em class="parameter"><code>append_if_existing</code></em> is set to
<a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a>, the an existing global list will be overwritten.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>reg_env</code></em> :</span></p></td>
<td>a GSList pointer.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>append_if_existing</code></em> :</span></p></td>
<td>whether or not to append to the global list.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="bonobo-activation-register-active-server"></a><h3>bonobo_activation_register_active_server ()</h3>
<pre class="programlisting"><a class="link" href="bonobo-activation-Registration.html#Bonobo-RegistrationResult" title="enum Bonobo_RegistrationResult"><span class="returnvalue">Bonobo_RegistrationResult</span></a>  bonobo_activation_register_active_server
                                                        (<em class="parameter"><code>const <span class="type">char</span> *iid</code></em>,
                                                         <em class="parameter"><code><span class="type">CORBA_Object</span> obj</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Singly-Linked-Lists.html#GSList"><span class="type">GSList</span></a> *reg_env</code></em>);</pre>
<p>
Registers <em class="parameter"><code>obj</code></em> with <em class="parameter"><code>iid</code></em> with the local bonobo-activation-server
daemon.
</p>
<p>
If <em class="parameter"><code>reg_env</code></em> is not <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>, <em class="parameter"><code>obj</code></em> will be registered in such a
way that if a client who's environment differs from the
environment specified in <em class="parameter"><code>reg_env</code></em>, then another attempt
to activate <em class="parameter"><code>iid</code></em> will not result in a reference to <em class="parameter"><code>obj</code></em>
being returned, but rather another instance of <em class="parameter"><code>iid</code></em> being
activated.
</p>
<p>
So, for example, you can ensure that a seperate instance
of the component is activated for each distinct X display
(and screen) by:
</p>
<p>
</p>
<div class="informalexample"><pre class="programlisting">
  display_name = gdk_display_get_name (gdk_display_get_default());
  reg_env = bonobo_activation_registration_env_set (
                             reg_env, "DISPLAY", display_name);
  bonobo_activation_register_active_server (iid, active_server, reg_env);
  bonobo_activation_registration_env_free (reg_env);
</pre></div>
<p>
</p>
<p>
If <em class="parameter"><code>reg_env</code></em> is <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>, the global registration environment
list will be used if it is set. See
<a class="link" href="bonobo-activation-Registration.html#bonobo-activation-registration-env-set-global" title="bonobo_activation_registration_env_set_global ()"><code class="function">bonobo_activation_registration_env_set_global()</code></a>.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>iid</code></em> :</span></p></td>
<td>IID of the server to register.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>obj</code></em> :</span></p></td>
<td>CORBA::Object to register.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>reg_env</code></em> :</span></p></td>
<td>the registration environment.</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>status of the registration.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="bonobo-activation-iid-get"></a><h3>bonobo_activation_iid_get ()</h3>
<pre class="programlisting">const <span class="returnvalue">char</span> *        bonobo_activation_iid_get           (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
<p>
</p>
</div>
<hr>
<div class="refsect2">
<a name="BonoboActivationPlugin"></a><h3>BonoboActivationPlugin</h3>
<pre class="programlisting">typedef struct {
	const BonoboActivationPluginObject *plugin_object_list;
	const char *description;
        gpointer dummy[8];
} BonoboActivationPlugin;
</pre>
<p>
Components which want to be activated as
shared libraries must export an BonoboActivationPlugin
structure of name <span class="structname">Bonobo_Plugin_info</span>.
An exmaple of how to use it folows:
</p>
<pre class="programlisting">
static CORBA_Object
hi_shlib_make_object (PortableServer_POA poa,
                      const char *iid,
                      gpointer impl_ptr,
                      CORBA_Environment *ev)
{
        CORBA_Object object_ref;
        object_ref = impl_Hi__create (poa, ev);
        if (object_ref == CORBA_OBJECT_NIL
            || ev-&gt;_major != CORBA_NO_EXCEPTION) {
                printf ("Server cannot get objref\n");
                return CORBA_OBJECT_NIL;
        }
        bonobo_activation_plugin_use (poa, impl_ptr);
        return object_ref;
}
static const BonoboActivationPluginObject hi_plugin_list[] = {
        {
                "OAFIID:Hi:20000923",
                hi_shlib_make_object
        },
        {
                NULL
  	}
};
const BonoboActivationPlugin Bonobo_Plugin_info = {
        hi_plugin_list,
        "Hi example"
};
</pre>
<p>
</p>
</div>
<hr>
<div class="refsect2">
<a name="BonoboActivationPluginObject"></a><h3>BonoboActivationPluginObject</h3>
<pre class="programlisting">typedef struct {
	const char *iid;

	/* This routine should call bonobo_activation_plugin_use(servant, impl_ptr), 
         * as should all routines which activate CORBA objects
	 * implemented by this shared library. This needs to be done 
         * before making any CORBA calls on the object, or
	 * passing that object around. First thing after servant creation 
         * always works. :) 
         */

        CORBA_Object (*activate) (PortableServer_POA poa,
                                  const char *iid, 
                                  gpointer impl_ptr, /* This pointer should be stored by the implementation
                                                         * to be passed to bonobo_activation_plugin_unuse() in the 
                                                         * implementation's destruction routine. */
				  CORBA_Environment *ev);
        gpointer dummy[4];
} BonoboActivationPluginObject;
</pre>
<p>
</p>
</div>
<hr>
<div class="refsect2">
<a name="bonobo-activation-plugin-use"></a><h3>bonobo_activation_plugin_use ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                bonobo_activation_plugin_use        (<em class="parameter"><code><span class="type">PortableServer_Servant</span> servant</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> impl_ptr</code></em>);</pre>
<p>
You should call this routine to activate a shared library-based 
CORBA Object. It will be called by OAF if the component exports 
correctly an <a class="link" href="bonobo-activation-Registration.html#BonoboActivationPlugin" title="BonoboActivationPlugin"><code class="literal">BonoboActivationPlugin</code></a> structure named "Bonobo_Plugin_info".
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>servant</code></em> :</span></p></td>
<td>The servant that was created</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>impl_ptr</code></em> :</span></p></td>
<td>The impl_ptr that was passed to the original activation routine</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="bonobo-activation-plugin-unuse"></a><h3>bonobo_activation_plugin_unuse ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                bonobo_activation_plugin_unuse      (<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> impl_ptr</code></em>);</pre>
<p>
Side effects: May arrange for the shared library that the
implementation is in to be unloaded.
</p>
<p>
When a shlib plugin for a CORBA object is destroying an
implementation, it should call this function to make sure that the
shared library is unloaded as needed.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><em class="parameter"><code>impl_ptr</code></em> :</span></p></td>
<td>The impl_ptr that was passed to the activation routine</td>
</tr></tbody>
</table></div>
</div>
</div>
</div>
<div class="footer">
<hr>
          Generated by GTK-Doc V1.16</div>
</body>
</html>