This file is indexed.

/usr/share/gtk-doc/html/goa/GoaOAuth2Provider.html is in libgoa-1.0-doc 3.4.0-0ubuntu1.1.

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
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>GoaOAuth2Provider</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.76.1">
<link rel="home" href="index.html" title="GNOME Online Accounts Reference Manual">
<link rel="up" href="ch07.html" title="Core">
<link rel="prev" href="GoaOAuthProvider.html" title="GoaOAuthProvider">
<link rel="next" href="ch08.html" title="Providers">
<meta name="generator" content="GTK-Doc V1.18 (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="GoaOAuthProvider.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
<td><a accesskey="u" href="ch07.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">GNOME Online Accounts Reference Manual</th>
<td><a accesskey="n" href="ch08.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
</tr>
<tr><td colspan="5" class="shortcuts">
<a href="#GoaOAuth2Provider.synopsis" class="shortcut">Top</a>
                   | 
                  <a href="#GoaOAuth2Provider.description" class="shortcut">Description</a>
                   | 
                  <a href="#GoaOAuth2Provider.object-hierarchy" class="shortcut">Object Hierarchy</a>
</td></tr>
</table>
<div class="refentry">
<a name="GoaOAuth2Provider"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle"><a name="GoaOAuth2Provider.top_of_page"></a>GoaOAuth2Provider</span></h2>
<p>GoaOAuth2Provider — Abstract base class for OAuth 2.0 providers</p>
</td>
<td valign="top" align="right"></td>
</tr></table></div>
<div class="refsynopsisdiv">
<a name="GoaOAuth2Provider.synopsis"></a><h2>Synopsis</h2>
<pre class="synopsis">                    <a class="link" href="GoaOAuth2Provider.html#GoaOAuth2Provider-struct" title="GoaOAuth2Provider">GoaOAuth2Provider</a>;
struct              <a class="link" href="GoaOAuth2Provider.html#GoaOAuth2ProviderClass" title="struct GoaOAuth2ProviderClass">GoaOAuth2ProviderClass</a>;
const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *       <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-authorization-uri" title="goa_oauth2_provider_get_authorization_uri ()">goa_oauth2_provider_get_authorization_uri</a>
                                                        (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>);
const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *       <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-token-uri" title="goa_oauth2_provider_get_token_uri ()">goa_oauth2_provider_get_token_uri</a>   (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>);
const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *       <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-redirect-uri" title="goa_oauth2_provider_get_redirect_uri ()">goa_oauth2_provider_get_redirect_uri</a>
                                                        (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>);
const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *       <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-scope" title="goa_oauth2_provider_get_scope ()">goa_oauth2_provider_get_scope</a>       (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>);
const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *       <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-client-id" title="goa_oauth2_provider_get_client_id ()">goa_oauth2_provider_get_client_id</a>   (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>);
const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *       <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-client-secret" title="goa_oauth2_provider_get_client_secret ()">goa_oauth2_provider_get_client_secret</a>
                                                        (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *             <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-build-authorization-uri" title="goa_oauth2_provider_build_authorization_uri ()">goa_oauth2_provider_build_authorization_uri</a>
                                                        (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>,
                                                         <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *authorization_uri</code></em>,
                                                         <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *escaped_redirect_uri</code></em>,
                                                         <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *escaped_client_id</code></em>,
                                                         <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *escaped_scope</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-use-external-browser" title="goa_oauth2_provider_get_use_external_browser ()">goa_oauth2_provider_get_use_external_browser</a>
                                                        (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-add-account-key-values" title="goa_oauth2_provider_add_account_key_values ()">goa_oauth2_provider_add_account_key_values</a>
                                                        (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-GVariant.html#GVariantBuilder"><span class="type">GVariantBuilder</span></a> *builder</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *             <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-identity-sync" title="goa_oauth2_provider_get_identity_sync ()">goa_oauth2_provider_get_identity_sync</a>
                                                        (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>,
                                                         <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *access_token</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> **out_presentation_identity</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/gio/GCancellable.html"><span class="type">GCancellable</span></a> *cancellable</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *             <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-access-token-sync" title="goa_oauth2_provider_get_access_token_sync ()">goa_oauth2_provider_get_access_token_sync</a>
                                                        (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>,
                                                         <em class="parameter"><code><a class="link" href="GoaObject.html" title="GoaObject"><span class="type">GoaObject</span></a> *object</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> force_refresh</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *out_access_token_expires_in</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/gio/GCancellable.html"><span class="type">GCancellable</span></a> *cancellable</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);
</pre>
</div>
<div class="refsect1">
<a name="GoaOAuth2Provider.object-hierarchy"></a><h2>Object Hierarchy</h2>
<pre class="synopsis">
  <a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObject">GObject</a>
   +----<a class="link" href="GoaProvider.html" title="GoaProvider">GoaProvider</a>
         +----GoaOAuth2Provider
               +----<a class="link" href="GoaFacebookProvider.html" title="GoaFacebookProvider">GoaFacebookProvider</a>
               +----<a class="link" href="GoaWindowsLiveProvider.html" title="GoaWindowsLiveProvider">GoaWindowsLiveProvider</a>
</pre>
</div>
<div class="refsect1">
<a name="GoaOAuth2Provider.description"></a><h2>Description</h2>
<p>
<a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> is an abstract base class for <a class="ulink" href="http://tools.ietf.org/html/draft-ietf-oauth-v2-15" target="_top">OAuth
2.0</a> based providers.
</p>
<p>
Subclasses must implement
<a class="link" href="GoaOAuth2Provider.html#GoaOAuth2ProviderClass.get-authorization-uri"><span class="type">GoaOAuth2ProviderClass.get_authorization_uri</span></a>,
<a class="link" href="GoaOAuth2Provider.html#GoaOAuth2ProviderClass.get-token-uri"><span class="type">GoaOAuth2ProviderClass.get_token_uri</span></a>,
<a class="link" href="GoaOAuth2Provider.html#GoaOAuth2ProviderClass.get-redirect-uri"><span class="type">GoaOAuth2ProviderClass.get_redirect_uri</span></a>,
<a class="link" href="GoaOAuth2Provider.html#GoaOAuth2ProviderClass.get-scope"><span class="type">GoaOAuth2ProviderClass.get_scope</span></a>,
<a class="link" href="GoaOAuth2Provider.html#GoaOAuth2ProviderClass.get-client-id"><span class="type">GoaOAuth2ProviderClass.get_client_id</span></a>,
<a class="link" href="GoaOAuth2Provider.html#GoaOAuth2ProviderClass.get-client-secret"><span class="type">GoaOAuth2ProviderClass.get_client_secret</span></a> and
<a class="link" href="GoaOAuth2Provider.html#GoaOAuth2ProviderClass.get-identity-sync"><span class="type">GoaOAuth2ProviderClass.get_identity_sync</span></a> methods.
</p>
<p>
Additionally, the
<a class="link" href="GoaProvider.html#GoaProviderClass.get-provider-type"><span class="type">GoaProviderClass.get_provider_type</span></a>,
<a class="link" href="GoaProvider.html#GoaProviderClass.get-provider-name"><span class="type">GoaProviderClass.get_provider_name</span></a>,
<a class="link" href="GoaProvider.html#GoaProviderClass.build-object"><span class="type">GoaProviderClass.build_object</span></a> (this should chain up to its
parent class) methods must be implemented.
</p>
<p>
Note that the <a class="link" href="GoaProvider.html#GoaProviderClass.add-account"><span class="type">GoaProviderClass.add_account</span></a>,
<a class="link" href="GoaProvider.html#GoaProviderClass.refresh-account"><span class="type">GoaProviderClass.refresh_account</span></a> and
<a class="link" href="GoaProvider.html#GoaProviderClass.ensure-credentials-sync"><span class="type">GoaProviderClass.ensure_credentials_sync</span></a> methods do not
need to be implemented - this type implements these methods..
</p>
</div>
<div class="refsect1">
<a name="GoaOAuth2Provider.details"></a><h2>Details</h2>
<div class="refsect2">
<a name="GoaOAuth2Provider-struct"></a><h3>GoaOAuth2Provider</h3>
<pre class="programlisting">typedef struct _GoaOAuth2Provider GoaOAuth2Provider;</pre>
<p>
The <a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> structure contains only private data and should
only be accessed using the provided API.
</p>
</div>
<hr>
<div class="refsect2">
<a name="GoaOAuth2ProviderClass"></a><h3>struct GoaOAuth2ProviderClass</h3>
<pre class="programlisting">struct GoaOAuth2ProviderClass {
  GoaProviderClass parent_class;

  /* pure virtual */
  const gchar *(*get_authorization_uri)    (GoaOAuth2Provider  *provider);
  const gchar *(*get_token_uri)            (GoaOAuth2Provider  *provider);
  const gchar *(*get_redirect_uri)         (GoaOAuth2Provider  *provider);
  const gchar *(*get_scope)                (GoaOAuth2Provider  *provider);
  const gchar *(*get_client_id)            (GoaOAuth2Provider  *provider);
  const gchar *(*get_client_secret)        (GoaOAuth2Provider  *provider);
  gchar       *(*get_identity_sync)        (GoaOAuth2Provider  *provider,
                                            const gchar        *access_token,
                                            gchar             **out_presentation_identity,
                                            GCancellable       *cancellable,
                                            GError            **error);

  /* virtual but with default implementation */
  gchar       *(*build_authorization_uri)  (GoaOAuth2Provider  *provider,
                                            const gchar        *authorization_uri,
                                            const gchar        *escaped_redirect_uri,
                                            const gchar        *escaped_client_id,
                                            const gchar        *escaped_scope);
  gboolean     (*get_use_external_browser) (GoaOAuth2Provider  *provider);
  void         (*add_account_key_values)   (GoaOAuth2Provider  *provider,
                                            GVariantBuilder    *builder);
};
</pre>
<p>
Class structure for <a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a>.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><a class="link" href="GoaProvider.html#GoaProviderClass" title="struct GoaProviderClass"><span class="type">GoaProviderClass</span></a> <em class="structfield"><code><a name="GoaOAuth2ProviderClass.parent-class"></a>parent_class</code></em>;</span></p></td>
<td>The parent class.</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GoaOAuth2ProviderClass.get-authorization-uri"></a>get_authorization_uri</code></em> ()</span></p></td>
<td>Virtual function for <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-authorization-uri" title="goa_oauth2_provider_get_authorization_uri ()"><code class="function">goa_oauth2_provider_get_authorization_uri()</code></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GoaOAuth2ProviderClass.get-token-uri"></a>get_token_uri</code></em> ()</span></p></td>
<td>Virtual function for <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-token-uri" title="goa_oauth2_provider_get_token_uri ()"><code class="function">goa_oauth2_provider_get_token_uri()</code></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GoaOAuth2ProviderClass.get-redirect-uri"></a>get_redirect_uri</code></em> ()</span></p></td>
<td>Virtual function for <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-redirect-uri" title="goa_oauth2_provider_get_redirect_uri ()"><code class="function">goa_oauth2_provider_get_redirect_uri()</code></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GoaOAuth2ProviderClass.get-scope"></a>get_scope</code></em> ()</span></p></td>
<td>Virtual function for <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-scope" title="goa_oauth2_provider_get_scope ()"><code class="function">goa_oauth2_provider_get_scope()</code></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GoaOAuth2ProviderClass.get-client-id"></a>get_client_id</code></em> ()</span></p></td>
<td>Virtual function for <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-client-id" title="goa_oauth2_provider_get_client_id ()"><code class="function">goa_oauth2_provider_get_client_id()</code></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GoaOAuth2ProviderClass.get-client-secret"></a>get_client_secret</code></em> ()</span></p></td>
<td>Virtual function for <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-client-secret" title="goa_oauth2_provider_get_client_secret ()"><code class="function">goa_oauth2_provider_get_client_secret()</code></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GoaOAuth2ProviderClass.get-identity-sync"></a>get_identity_sync</code></em> ()</span></p></td>
<td>Virtual function for <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-identity-sync" title="goa_oauth2_provider_get_identity_sync ()"><code class="function">goa_oauth2_provider_get_identity_sync()</code></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GoaOAuth2ProviderClass.build-authorization-uri"></a>build_authorization_uri</code></em> ()</span></p></td>
<td>Virtual function for <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-build-authorization-uri" title="goa_oauth2_provider_build_authorization_uri ()"><code class="function">goa_oauth2_provider_build_authorization_uri()</code></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GoaOAuth2ProviderClass.get-use-external-browser"></a>get_use_external_browser</code></em> ()</span></p></td>
<td>Virtual function for <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-use-external-browser" title="goa_oauth2_provider_get_use_external_browser ()"><code class="function">goa_oauth2_provider_get_use_external_browser()</code></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GoaOAuth2ProviderClass.add-account-key-values"></a>add_account_key_values</code></em> ()</span></p></td>
<td>Virtual function for <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-add-account-key-values" title="goa_oauth2_provider_add_account_key_values ()"><code class="function">goa_oauth2_provider_add_account_key_values()</code></a>.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="goa-oauth2-provider-get-authorization-uri"></a><h3>goa_oauth2_provider_get_authorization_uri ()</h3>
<pre class="programlisting">const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *       goa_oauth2_provider_get_authorization_uri
                                                        (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>);</pre>
<p>
Gets the <a class="ulink" href="http://tools.ietf.org/html/draft-ietf-oauth-v2-15#section-2.1" target="_top">authorization
endpoint</a> used for authenticating the user and obtaining
authorization.
</p>
<p>
You should not include any parameters in the returned URI. If you
need to include additional parameters than the standard ones,
override <a class="link" href="GoaOAuth2Provider.html#GoaOAuth2ProviderClass.build-authorization-uri"><span class="type">GoaOAuth2ProviderClass.build_authorization_uri</span></a> -
see <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-build-authorization-uri" title="goa_oauth2_provider_build_authorization_uri ()"><code class="function">goa_oauth2_provider_build_authorization_uri()</code></a> for more
details.
</p>
<p>
This is a pure virtual method - a subclass must provide an
implementation.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>provider</code></em> :</span></p></td>
<td>A <a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a>.</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>A string owned by <em class="parameter"><code>provider</code></em> - do not free. <span class="annotation">[<a href="http://foldoc.org/transfer%20none"><span class="acronym">transfer none</span></a>]</span>
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="goa-oauth2-provider-get-token-uri"></a><h3>goa_oauth2_provider_get_token_uri ()</h3>
<pre class="programlisting">const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *       goa_oauth2_provider_get_token_uri   (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>);</pre>
<p>
Gets the <a class="ulink" href="http://tools.ietf.org/html/draft-ietf-oauth-v2-15#section-2.2" target="_top">token
endpoint</a> used for obtaining an access token.
</p>
<p>
You should not include any parameters in the returned URI.
</p>
<p>
This is a pure virtual method - a subclass must provide an
implementation.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>provider</code></em> :</span></p></td>
<td>A <a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a>.</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>A string owned by <em class="parameter"><code>provider</code></em> - do not free. <span class="annotation">[<a href="http://foldoc.org/transfer%20none"><span class="acronym">transfer none</span></a>]</span>
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="goa-oauth2-provider-get-redirect-uri"></a><h3>goa_oauth2_provider_get_redirect_uri ()</h3>
<pre class="programlisting">const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *       goa_oauth2_provider_get_redirect_uri
                                                        (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>);</pre>
<p>
Gets the <a class="ulink" href="http://tools.ietf.org/html/draft-ietf-oauth-v2-15#section-2.1.1" target="_top">redirect_uri</a>
used when requesting authorization.
</p>
<p>
This is a pure virtual method - a subclass must provide an
implementation.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>provider</code></em> :</span></p></td>
<td>A <a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a>.</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>A string owned by <em class="parameter"><code>provider</code></em> - do not free. <span class="annotation">[<a href="http://foldoc.org/transfer%20none"><span class="acronym">transfer none</span></a>]</span>
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="goa-oauth2-provider-get-scope"></a><h3>goa_oauth2_provider_get_scope ()</h3>
<pre class="programlisting">const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *       goa_oauth2_provider_get_scope       (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>);</pre>
<p>
Gets the <a class="ulink" href="http://tools.ietf.org/html/draft-ietf-oauth-v2-15#section-2.1.1" target="_top">scope</a>
used when requesting authorization.
</p>
<p>
This is a pure virtual method - a subclass must provide an
implementation.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>provider</code></em> :</span></p></td>
<td>A <a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a>.</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>A string owned by <em class="parameter"><code>provider</code></em> - do not free. <span class="annotation">[<a href="http://foldoc.org/transfer%20none"><span class="acronym">transfer none</span></a>]</span>
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="goa-oauth2-provider-get-client-id"></a><h3>goa_oauth2_provider_get_client_id ()</h3>
<pre class="programlisting">const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *       goa_oauth2_provider_get_client_id   (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>);</pre>
<p>
Gets the <a class="ulink" href="http://tools.ietf.org/html/draft-ietf-oauth-v2-15#section-3" target="_top">client_id</a>
identifying the client.
</p>
<p>
This is a pure virtual method - a subclass must provide an
implementation.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>provider</code></em> :</span></p></td>
<td>A <a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a>.</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>A string owned by <em class="parameter"><code>provider</code></em> - do not free. <span class="annotation">[<a href="http://foldoc.org/transfer%20none"><span class="acronym">transfer none</span></a>]</span>
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="goa-oauth2-provider-get-client-secret"></a><h3>goa_oauth2_provider_get_client_secret ()</h3>
<pre class="programlisting">const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *       goa_oauth2_provider_get_client_secret
                                                        (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>);</pre>
<p>
Gets the <a class="ulink" href="http://tools.ietf.org/html/draft-ietf-oauth-v2-15#section-3" target="_top">client_secret</a>
associated with the client.
</p>
<p>
This is a pure virtual method - a subclass must provide an
implementation.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>provider</code></em> :</span></p></td>
<td>A <a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a>.</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>A string owned by <em class="parameter"><code>provider</code></em> - do not free. <span class="annotation">[<a href="http://foldoc.org/transfer%20none"><span class="acronym">transfer none</span></a>]</span>
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="goa-oauth2-provider-build-authorization-uri"></a><h3>goa_oauth2_provider_build_authorization_uri ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *             goa_oauth2_provider_build_authorization_uri
                                                        (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>,
                                                         <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *authorization_uri</code></em>,
                                                         <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *escaped_redirect_uri</code></em>,
                                                         <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *escaped_client_id</code></em>,
                                                         <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *escaped_scope</code></em>);</pre>
<p>
Builds the URI that can be opened in a web browser (or embedded web
browser widget) to start authenticating an user.
</p>
<p>
The default implementation just returns the expected URI
(e.g. <code class="literal">http://example.com/dialog/oauth2?response_type=code&amp;redirect_uri=https<code class="literal">3A</code>%2F<code class="literal">2Fclient</code>%2Eexample<code class="literal">2Ecom</code>%2Fcb&amp;client_id=foo&amp;scope=email<code class="literal">20stuff</code></code>)
</p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem"><p>override (and chain up) if you e.g. need to to pass additional
parameters.</p></li></ul></div>
<p>
</p>
<p>
The <em class="parameter"><code>authorization_uri</code></em>, <em class="parameter"><code>escaped_redirect_uri</code></em>, <em class="parameter"><code>escaped_client_id</code></em>
and <em class="parameter"><code>escaped_scope</code></em> parameters originate from the result of the
the <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-authorization-uri" title="goa_oauth2_provider_get_authorization_uri ()"><code class="function">goa_oauth2_provider_get_authorization_uri()</code></a>, <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-redirect-uri" title="goa_oauth2_provider_get_redirect_uri ()"><code class="function">goa_oauth2_provider_get_redirect_uri()</code></a>, <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-client-id" title="goa_oauth2_provider_get_client_id ()"><code class="function">goa_oauth2_provider_get_client_id()</code></a>
and <a class="link" href="GoaOAuth2Provider.html#goa-oauth2-provider-get-scope" title="goa_oauth2_provider_get_scope ()"><code class="function">goa_oauth2_provider_get_scope()</code></a> methods with the latter
three escaped using <a href="/usr/share/gtk-doc/html/glib/glib-URI-Functions.html#g-uri-escape-string"><code class="function">g_uri_escape_string()</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>provider</code></em> :</span></p></td>
<td>A <a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>authorization_uri</code></em> :</span></p></td>
<td>An authorization URI.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>escaped_redirect_uri</code></em> :</span></p></td>
<td>An escaped redirect URI</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>escaped_client_id</code></em> :</span></p></td>
<td>An escaped client id</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>escaped_scope</code></em> :</span></p></td>
<td>The escaped scope.</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>An authorization URI that must be freed with <a href="/usr/share/gtk-doc/html/glib/glib-Memory-Allocation.html#g-free"><code class="function">g_free()</code></a>. <span class="annotation">[<a href="http://foldoc.org/transfer%20full"><span class="acronym">transfer full</span></a>]</span>
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="goa-oauth2-provider-get-use-external-browser"></a><h3>goa_oauth2_provider_get_use_external_browser ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            goa_oauth2_provider_get_use_external_browser
                                                        (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>);</pre>
<p>
Returns whether an external browser (the users default browser)
should be used for user interaction.
</p>
<p>
If an external browser is used, then the dialogs presented in
<a class="link" href="GoaProvider.html#goa-provider-add-account" title="goa_provider_add_account ()"><code class="function">goa_provider_add_account()</code></a> and
<a class="link" href="GoaProvider.html#goa-provider-refresh-account" title="goa_provider_refresh_account ()"><code class="function">goa_provider_refresh_account()</code></a> will show a simple "Paste
authorization code here" instructions along with an entry and
button.
</p>
<p>
This is a virtual method where the default implementation returns
<a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</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>provider</code></em> :</span></p></td>
<td>A <a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a>.</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>
<a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if the user interaction should happen in an external
browser, <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> to use an embedded browser widget.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="goa-oauth2-provider-add-account-key-values"></a><h3>goa_oauth2_provider_add_account_key_values ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                goa_oauth2_provider_add_account_key_values
                                                        (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-GVariant.html#GVariantBuilder"><span class="type">GVariantBuilder</span></a> *builder</code></em>);</pre>
<p>
Hook for implementations to add key/value pairs to the key-file
when creating an account.
</p>
<p>
This is a virtual method where the default implementation does nothing.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>provider</code></em> :</span></p></td>
<td>A <a class="link" href="GoaProvider.html" title="GoaProvider"><span class="type">GoaProvider</span></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>builder</code></em> :</span></p></td>
<td>A <a href="/usr/share/gtk-doc/html/glib/glib-GVariant.html#GVariantBuilder"><span class="type">GVariantBuilder</span></a> for a <code class="literal">a{ss}</code> variant.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="goa-oauth2-provider-get-identity-sync"></a><h3>goa_oauth2_provider_get_identity_sync ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *             goa_oauth2_provider_get_identity_sync
                                                        (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>,
                                                         <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *access_token</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> **out_presentation_identity</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/gio/GCancellable.html"><span class="type">GCancellable</span></a> *cancellable</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre>
<p>
Method that returns the identity corresponding to
<em class="parameter"><code>access_token</code></em>.
</p>
<p>
The identity is needed because all authentication happens out of
band. In addition to the identity, an implementation also returns a
<span class="emphasis"><em>presentation identity</em></span> that is more suitable
for presentation (the identity could be a GUID for example).
</p>
<p>
The calling thread is blocked while the identity is obtained.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>provider</code></em> :</span></p></td>
<td>A <a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>access_token</code></em> :</span></p></td>
<td>A valid OAuth 2.0 access token.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>out_presentation_identity</code></em> :</span></p></td>
<td>Return location for presentation identity or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<a href="http://foldoc.org/out"><span class="acronym">out</span></a>]</span>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>cancellable</code></em> :</span></p></td>
<td>A <a href="/usr/share/gtk-doc/html/gio/GCancellable.html"><span class="type">GCancellable</span></a> or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<a href="http://foldoc.org/allow-none"><span class="acronym">allow-none</span></a>]</span>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>error</code></em> :</span></p></td>
<td>Return location for <em class="parameter"><code>error</code></em> or <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 identity or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if error is set. The returned string
must be freed with <a href="/usr/share/gtk-doc/html/glib/glib-Memory-Allocation.html#g-free"><code class="function">g_free()</code></a>.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="goa-oauth2-provider-get-access-token-sync"></a><h3>goa_oauth2_provider_get_access_token_sync ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *             goa_oauth2_provider_get_access_token_sync
                                                        (<em class="parameter"><code><a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a> *provider</code></em>,
                                                         <em class="parameter"><code><a class="link" href="GoaObject.html" title="GoaObject"><span class="type">GoaObject</span></a> *object</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> force_refresh</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *out_access_token_expires_in</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/gio/GCancellable.html"><span class="type">GCancellable</span></a> *cancellable</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre>
<p>
Synchronously gets an access token for <em class="parameter"><code>object</code></em>. The calling thread
is blocked while the operation is pending.
</p>
<p>
The resulting token is typically read from the local cache so most
of the time only a local roundtrip to the storage for the token
cache (e.g. <span class="command"><strong>gnome-keyring-daemon</strong></span>) is
needed. However, the operation may involve refreshing the token
with the service provider so a full network round-trip may be
needed.
</p>
<p>
Note that multiple calls are serialized to avoid multiple
outstanding requests to the service provider.
</p>
<p>
This operation may fail if e.g. unable to refresh the credentials
or if network connectivity is not available. Note that even if a
token is returned, the returned token isn't guaranteed to work -
use <a class="link" href="GoaProvider.html#goa-provider-ensure-credentials-sync" title="goa_provider_ensure_credentials_sync ()"><code class="function">goa_provider_ensure_credentials_sync()</code></a> if you need
stronger guarantees.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>provider</code></em> :</span></p></td>
<td>A <a class="link" href="GoaOAuth2Provider.html" title="GoaOAuth2Provider"><span class="type">GoaOAuth2Provider</span></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>object</code></em> :</span></p></td>
<td>A <a class="link" href="GoaObject.html" title="GoaObject"><span class="type">GoaObject</span></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>force_refresh</code></em> :</span></p></td>
<td>If set to <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a>, forces a refresh of the access token, if possible.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>out_access_token_expires_in</code></em> :</span></p></td>
<td>Return location for how many seconds the returned token is valid for (0 if unknown) or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<a href="http://foldoc.org/out"><span class="acronym">out</span></a>]</span>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>cancellable</code></em> :</span></p></td>
<td>A <a href="/usr/share/gtk-doc/html/gio/GCancellable.html"><span class="type">GCancellable</span></a> or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<a href="http://foldoc.org/allow-none"><span class="acronym">allow-none</span></a>]</span>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>error</code></em> :</span></p></td>
<td>Return location for error or <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 access token or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if error is set. The returned
string must be freed with <a href="/usr/share/gtk-doc/html/glib/glib-Memory-Allocation.html#g-free"><code class="function">g_free()</code></a>.</td>
</tr>
</tbody>
</table></div>
</div>
</div>
</div>
<div class="footer">
<hr>
          Generated by GTK-Doc V1.18</div>
</body>
</html>