Update to upstream 1.0.1
[profile/ivi/gsignond.git] / docs / html / GSignondConfig.html
1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2 <html>
3 <head>
4 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
5 <title>gsignond API Reference Manual: GSignondConfig</title>
6 <meta name="generator" content="DocBook XSL Stylesheets V1.78.1">
7 <link rel="home" href="index.html" title="gsignond API Reference Manual">
8 <link rel="up" href="ch02.html" title="GSignond configuration">
9 <link rel="prev" href="ch02.html" title="GSignond configuration">
10 <link rel="next" href="gsignond-General-configuration.html" title="General configuration">
11 <meta name="generator" content="GTK-Doc V1.20 (XML mode)">
12 <link rel="stylesheet" href="style.css" type="text/css">
13 </head>
14 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
15 <table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="10"><tr valign="middle">
16 <td width="100%" align="left" class="shortcuts">
17 <a href="#" class="shortcut">Top</a><span id="nav_description"> <span class="dim">|</span> 
18                   <a href="#GSignondConfig.description" class="shortcut">Description</a></span><span id="nav_hierarchy"> <span class="dim">|</span> 
19                   <a href="#GSignondConfig.object-hierarchy" class="shortcut">Object Hierarchy</a></span>
20 </td>
21 <td><a accesskey="h" href="index.html"><img src="home.png" width="16" height="16" border="0" alt="Home"></a></td>
22 <td><a accesskey="u" href="ch02.html"><img src="up.png" width="16" height="16" border="0" alt="Up"></a></td>
23 <td><a accesskey="p" href="ch02.html"><img src="left.png" width="16" height="16" border="0" alt="Prev"></a></td>
24 <td><a accesskey="n" href="gsignond-General-configuration.html"><img src="right.png" width="16" height="16" border="0" alt="Next"></a></td>
25 </tr></table>
26 <div class="refentry">
27 <a name="GSignondConfig"></a><div class="titlepage"></div>
28 <div class="refnamediv"><table width="100%"><tr>
29 <td valign="top">
30 <h2><span class="refentrytitle"><a name="GSignondConfig.top_of_page"></a>GSignondConfig</span></h2>
31 <p>GSignondConfig — gSSO configuration information</p>
32 </td>
33 <td class="gallery_image" valign="top" align="right"></td>
34 </tr></table></div>
35 <div class="refsect1">
36 <a name="GSignondConfig.functions"></a><h2>Functions</h2>
37 <div class="informaltable"><table width="100%" border="0">
38 <colgroup>
39 <col width="150px" class="functions_return">
40 <col class="functions_name">
41 </colgroup>
42 <tbody>
43 <tr>
44 <td class="function_type">
45 <a class="link" href="GSignondConfig.html" title="GSignondConfig"><span class="returnvalue">GSignondConfig</span></a> *
46 </td>
47 <td class="function_name">
48 <a class="link" href="GSignondConfig.html#gsignond-config-new" title="gsignond_config_new ()">gsignond_config_new</a> <span class="c_punctuation">()</span>
49 </td>
50 </tr>
51 <tr>
52 <td class="function_type">
53 <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="returnvalue">gint</span></a>
54 </td>
55 <td class="function_name">
56 <a class="link" href="GSignondConfig.html#gsignond-config-get-integer" title="gsignond_config_get_integer ()">gsignond_config_get_integer</a> <span class="c_punctuation">()</span>
57 </td>
58 </tr>
59 <tr>
60 <td class="function_type">
61 <span class="returnvalue">void</span>
62 </td>
63 <td class="function_name">
64 <a class="link" href="GSignondConfig.html#gsignond-config-set-integer" title="gsignond_config_set_integer ()">gsignond_config_set_integer</a> <span class="c_punctuation">()</span>
65 </td>
66 </tr>
67 <tr>
68 <td class="function_type">const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
69 </td>
70 <td class="function_name">
71 <a class="link" href="GSignondConfig.html#gsignond-config-get-string" title="gsignond_config_get_string ()">gsignond_config_get_string</a> <span class="c_punctuation">()</span>
72 </td>
73 </tr>
74 <tr>
75 <td class="function_type">
76 <span class="returnvalue">void</span>
77 </td>
78 <td class="function_name">
79 <a class="link" href="GSignondConfig.html#gsignond-config-set-string" title="gsignond_config_set_string ()">gsignond_config_set_string</a> <span class="c_punctuation">()</span>
80 </td>
81 </tr>
82 </tbody>
83 </table></div>
84 </div>
85 <div class="refsect1">
86 <a name="GSignondConfig.object-hierarchy"></a><h2>Object Hierarchy</h2>
87 <pre class="screen">    <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject">GObject</a>
88     <span class="lineart">╰──</span> GSignondConfig
89 </pre>
90 </div>
91 <div class="refsect1">
92 <a name="GSignondConfig.includes"></a><h2>Includes</h2>
93 <pre class="synopsis">#include &lt;gsignond/gsignond-config.h&gt;
94 </pre>
95 </div>
96 <div class="refsect1">
97 <a name="GSignondConfig.description"></a><h2>Description</h2>
98 <p><a class="link" href="GSignondConfig.html" title="GSignondConfig"><span class="type">GSignondConfig</span></a> holds configuration information as a set of keys and values
99 (integer or strings). The key names are defined in </p>
100 <a class="link" href="gsignond-General-configuration.html" title="General configuration">general config keys</a>,
101 <p>and <a class="link" href="gsignond-DBus-configuration.html" title="DBus configuration">DBus config keys</a>.</p>
102 <p>The configuration is retrieved from the gSSO configuration file. See below 
103 for where the file is searched for.</p>
104 <div class="refsect1">
105 <a name="id-1.3.2.6.6"></a><h2>Where the configuration file is searched for</h2>
106 </div>
107 <p>If gSSO has been compiled with --enable-debug, then these locations are used,
108 in decreasing order of priority:</p>
109 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
110 <li class="listitem"><p>GSIGNOND_CONFIG environment variable</p></li>
111 <li class="listitem"><p>g_get_user_config_dir() + "gsignond.conf"</p></li>
112 <li class="listitem"><p>path specified in --sysconfdir configure option ($(sysconfdir))</p></li>
113 <li class="listitem"><p>each of <a href="http://library.gnome.org/devel/glib/unstable/glib-Miscellaneous-Utility-Functions.html#g-get-system-config-dirs"><code class="function">g_get_system_config_dirs()</code></a> + "gsignond.conf"</p></li>
114 </ul></div>
115 <p>Otherwise, the config file location is determined at compilation time as 
116 $(sysconfdir) + "gsignond.conf"</p>
117 <div class="refsect1">
118 <a name="id-1.3.2.6.10"></a><h2>Example configuration file</h2>
119 </div>
120 <p>See example configuration file here:</p>
121 <a class="ulink" href="http://code.google.com/p/accounts-sso/source/browse/gsignond.conf.in?repo=gsignond" target="_top">
122 http://code.google.com/p/accounts-sso/source/browse/gsignond.conf.in?repo=gsignond</a>
123 </div>
124 <div class="refsect1">
125 <a name="GSignondConfig.functions_details"></a><h2>Functions</h2>
126 <div class="refsect2">
127 <a name="gsignond-config-new"></a><h3>gsignond_config_new ()</h3>
128 <pre class="programlisting"><a class="link" href="GSignondConfig.html" title="GSignondConfig"><span class="returnvalue">GSignondConfig</span></a> *
129 gsignond_config_new ();</pre>
130 <p>Create a <a class="link" href="GSignondConfig.html" title="GSignondConfig"><span class="type">GSignondConfig</span></a> object.</p>
131 <div class="refsect3">
132 <a name="id-1.3.2.7.2.5"></a><h4>Returns</h4>
133 <p> an instance of <a class="link" href="GSignondConfig.html" title="GSignondConfig"><span class="type">GSignondConfig</span></a>. gSSO extensions should not use this
134 as they're already provided with a config object when they're created.</p>
135 <p></p>
136 </div>
137 </div>
138 <hr>
139 <div class="refsect2">
140 <a name="gsignond-config-get-integer"></a><h3>gsignond_config_get_integer ()</h3>
141 <pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="returnvalue">gint</span></a>
142 gsignond_config_get_integer (<em class="parameter"><code><a class="link" href="GSignondConfig.html" title="GSignondConfig"><span class="type">GSignondConfig</span></a> *self</code></em>,
143                              <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *key</code></em>);</pre>
144 <p>Get an integer configuration value.</p>
145 <div class="refsect3">
146 <a name="id-1.3.2.7.3.5"></a><h4>Parameters</h4>
147 <div class="informaltable"><table width="100%" border="0">
148 <colgroup>
149 <col width="150px" class="parameters_name">
150 <col class="parameters_description">
151 <col width="200px" class="parameters_annotations">
152 </colgroup>
153 <tbody>
154 <tr>
155 <td class="parameter_name"><p>self</p></td>
156 <td class="parameter_description"><p>an instance of <a class="link" href="GSignondConfig.html" title="GSignondConfig"><span class="type">GSignondConfig</span></a></p></td>
157 <td class="parameter_annotations"> </td>
158 </tr>
159 <tr>
160 <td class="parameter_name"><p>key</p></td>
161 <td class="parameter_description"><p>the key name</p></td>
162 <td class="parameter_annotations"> </td>
163 </tr>
164 </tbody>
165 </table></div>
166 </div>
167 <div class="refsect3">
168 <a name="id-1.3.2.7.3.6"></a><h4>Returns</h4>
169 <p> the value corresponding to the key as an integer. If the key does not
170 exist or cannot be converted to the integer, 0 is returned.</p>
171 <p></p>
172 </div>
173 </div>
174 <hr>
175 <div class="refsect2">
176 <a name="gsignond-config-set-integer"></a><h3>gsignond_config_set_integer ()</h3>
177 <pre class="programlisting"><span class="returnvalue">void</span>
178 gsignond_config_set_integer (<em class="parameter"><code><a class="link" href="GSignondConfig.html" title="GSignondConfig"><span class="type">GSignondConfig</span></a> *self</code></em>,
179                              <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *key</code></em>,
180                              <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> value</code></em>);</pre>
181 <p>Sets the configuration value to the provided integer.</p>
182 <div class="refsect3">
183 <a name="id-1.3.2.7.4.5"></a><h4>Parameters</h4>
184 <div class="informaltable"><table width="100%" border="0">
185 <colgroup>
186 <col width="150px" class="parameters_name">
187 <col class="parameters_description">
188 <col width="200px" class="parameters_annotations">
189 </colgroup>
190 <tbody>
191 <tr>
192 <td class="parameter_name"><p>self</p></td>
193 <td class="parameter_description"><p>an instance of <a class="link" href="GSignondConfig.html" title="GSignondConfig"><span class="type">GSignondConfig</span></a></p></td>
194 <td class="parameter_annotations"> </td>
195 </tr>
196 <tr>
197 <td class="parameter_name"><p>key</p></td>
198 <td class="parameter_description"><p>the key name</p></td>
199 <td class="parameter_annotations"> </td>
200 </tr>
201 <tr>
202 <td class="parameter_name"><p>value</p></td>
203 <td class="parameter_description"><p>the value</p></td>
204 <td class="parameter_annotations"> </td>
205 </tr>
206 </tbody>
207 </table></div>
208 </div>
209 </div>
210 <hr>
211 <div class="refsect2">
212 <a name="gsignond-config-get-string"></a><h3>gsignond_config_get_string ()</h3>
213 <pre class="programlisting">const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *
214 gsignond_config_get_string (<em class="parameter"><code><a class="link" href="GSignondConfig.html" title="GSignondConfig"><span class="type">GSignondConfig</span></a> *self</code></em>,
215                             <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *key</code></em>);</pre>
216 <p>Get a string configuration value.</p>
217 <div class="refsect3">
218 <a name="id-1.3.2.7.5.5"></a><h4>Parameters</h4>
219 <div class="informaltable"><table width="100%" border="0">
220 <colgroup>
221 <col width="150px" class="parameters_name">
222 <col class="parameters_description">
223 <col width="200px" class="parameters_annotations">
224 </colgroup>
225 <tbody>
226 <tr>
227 <td class="parameter_name"><p>self</p></td>
228 <td class="parameter_description"><p>an instance of <a class="link" href="GSignondConfig.html" title="GSignondConfig"><span class="type">GSignondConfig</span></a></p></td>
229 <td class="parameter_annotations"> </td>
230 </tr>
231 <tr>
232 <td class="parameter_name"><p>key</p></td>
233 <td class="parameter_description"><p>the key name</p></td>
234 <td class="parameter_annotations"> </td>
235 </tr>
236 </tbody>
237 </table></div>
238 </div>
239 <div class="refsect3">
240 <a name="id-1.3.2.7.5.6"></a><h4>Returns</h4>
241 <p> the value corresponding to the key as string. If the key does not
242 exist, NULL is returned. </p>
243 <p><span class="annotation">[<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>]</span></p>
244 </div>
245 </div>
246 <hr>
247 <div class="refsect2">
248 <a name="gsignond-config-set-string"></a><h3>gsignond_config_set_string ()</h3>
249 <pre class="programlisting"><span class="returnvalue">void</span>
250 gsignond_config_set_string (<em class="parameter"><code><a class="link" href="GSignondConfig.html" title="GSignondConfig"><span class="type">GSignondConfig</span></a> *self</code></em>,
251                             <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *key</code></em>,
252                             <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *value</code></em>);</pre>
253 <p>Sets the configuration value to the provided string.</p>
254 <div class="refsect3">
255 <a name="id-1.3.2.7.6.5"></a><h4>Parameters</h4>
256 <div class="informaltable"><table width="100%" border="0">
257 <colgroup>
258 <col width="150px" class="parameters_name">
259 <col class="parameters_description">
260 <col width="200px" class="parameters_annotations">
261 </colgroup>
262 <tbody>
263 <tr>
264 <td class="parameter_name"><p>self</p></td>
265 <td class="parameter_description"><p>an instance of <a class="link" href="GSignondConfig.html" title="GSignondConfig"><span class="type">GSignondConfig</span></a></p></td>
266 <td class="parameter_annotations"> </td>
267 </tr>
268 <tr>
269 <td class="parameter_name"><p>key</p></td>
270 <td class="parameter_description"><p>the key name</p></td>
271 <td class="parameter_annotations"> </td>
272 </tr>
273 <tr>
274 <td class="parameter_name"><p>value</p></td>
275 <td class="parameter_description"><p> the value. </p></td>
276 <td class="parameter_annotations"><span class="annotation">[<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>]</span></td>
277 </tr>
278 </tbody>
279 </table></div>
280 </div>
281 </div>
282 </div>
283 <div class="refsect1">
284 <a name="GSignondConfig.other_details"></a><h2>Types and Values</h2>
285 </div>
286 </div>
287 <div class="footer">
288 <hr>
289           Generated by GTK-Doc V1.20</div>
290 </body>
291 </html>