summaryrefslogtreecommitdiff
path: root/zend/documentation/api/core/files/Gdata.AuthSub.html
blob: a8aeadc0bc7199578128004b8c5cfae712e91ba8 (plain)
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
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"><head><title>Zend Gdata API Documentation</title><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></meta><link rel="stylesheet" href="../css/template.css" type="text/css"></link><script type="text/javascript" src="../js/jquery-1.4.2.min.js"></script><script type="text/javascript" src="../js/jquery.tools.min.js"></script><script type="text/javascript" src="../js/jquery-ui-1.8.2.custom.min.js"></script><script type="text/javascript" src="../js/template.js"></script></head><body><div id="content"><h1 class="file">Gdata/AuthSub.php</h1><div id="file-nav-box"><div id="file-nav-options">
              Show:
              <img src="../images/icons/visibility_public.png" alt="Public" id="show-public"></img><img src="../images/icons/visibility_protected.png" alt="Protected" id="show-protected"></img><img src="../images/icons/visibility_private.png" alt="Private" id="show-private"></img><span class="attribute" id="show-inherited">inherited</span></div><div id="file-nav-container"><ul id="file-nav"><li><a href="#classes"><img src="../images/icons/class.png" alt="Class" height="14"></img>
                          Classes
                      </a><ul><li><a href="#\Zend_Gdata_AuthSub">\Zend_Gdata_AuthSub</a></li></ul></li></ul><div style="clear: left;"></div></div><div id="file-nav-tab">
              Table of Contents
          </div></div><a name="top" class="anchor"></a><div id="file-description"><div class="short-description">Zend Framework</div><div class="long-description"><p>LICENSE</p>

<p>This source file is subject to the new BSD license that is bundled
with this package in the file LICENSE.txt.
It is also available through the world-wide-web at this URL:
http://framework.zend.com/license/new-bsd
If you did not receive a copy of the license and are unable to
obtain it through the world-wide-web, please send an email
to license@zend.com so we can send you a copy immediately.</p></div></div><dl class="file-info"><dt>Category</dt><dd>Zend
         
    </dd><dt>Copyright</dt><dd>Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
         
    </dd><dt>License</dt><dd><a href="http://framework.zend.com/license/new-bsd">New BSD License</a>
         
    </dd><dt>Package</dt><dd>Zend_Gdata
         
    </dd><dt>Subpackage</dt><dd>Gdata
         
    </dd><dt>Version</dt><dd>$Id: AuthSub.php 24593 2012-01-05 20:35:02Z matthew $
         
    </dd></dl><a name="classes" class="anchor"></a><a id="\Zend_Gdata_AuthSub" class="anchor"></a><h2 class="class">\Zend_Gdata_AuthSub<div class="to-top"><a href="#top">jump to top</a></div></h2><div class="class"><small class="package"><b>Package: </b>Zend\Gdata\Gdata</small><div class="short-description">Wrapper around Zend_Http_Client to facilitate Google's "Account Authentication
Proxy for Web-Based Applications".</div><div class="long-description"></div><dl class="class-info"><dt>See</dt><dd>\global\http://code.google.com/apis/accounts/AuthForWebApps.html
         
    </dd><dt>Category</dt><dd>Zend
         
    </dd><dt>Copyright</dt><dd>Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
         
    </dd><dt>License</dt><dd><a href="http://framework.zend.com/license/new-bsd">New BSD License</a>
         
    </dd></dl><h3>Constants</h3><div><a id="\Zend_Gdata_AuthSub::AUTHSUB_REQUEST_URI" class="anchor"></a><div class="constant publicC"><a href="#" class="gripper"><img src="../images/icons/arrow_right.png" alt="&gt;"></img><img src="../images/icons/arrow_down.png" alt="V" style="display: none;"></img></a><code class="title"><img src="../images/icons/constant.png" alt="Constant"></img> 
                <span class="highlight">AUTHSUB_REQUEST_URI</span>
                = 'https://www.google.com/accounts/AuthSubRequest'</code><div class="description"></div><div class="code-tabs"></div><div class="clear"></div></div><a id="\Zend_Gdata_AuthSub::AUTHSUB_SESSION_TOKEN_URI" class="anchor"></a><div class="constant publicC"><a href="#" class="gripper"><img src="../images/icons/arrow_right.png" alt="&gt;"></img><img src="../images/icons/arrow_down.png" alt="V" style="display: none;"></img></a><code class="title"><img src="../images/icons/constant.png" alt="Constant"></img> 
                <span class="highlight">AUTHSUB_SESSION_TOKEN_URI</span>
                = 'https://www.google.com/accounts/AuthSubSessionToken'</code><div class="description"></div><div class="code-tabs"></div><div class="clear"></div></div><a id="\Zend_Gdata_AuthSub::AUTHSUB_REVOKE_TOKEN_URI" class="anchor"></a><div class="constant publicC"><a href="#" class="gripper"><img src="../images/icons/arrow_right.png" alt="&gt;"></img><img src="../images/icons/arrow_down.png" alt="V" style="display: none;"></img></a><code class="title"><img src="../images/icons/constant.png" alt="Constant"></img> 
                <span class="highlight">AUTHSUB_REVOKE_TOKEN_URI</span>
                = 'https://www.google.com/accounts/AuthSubRevokeToken'</code><div class="description"></div><div class="code-tabs"></div><div class="clear"></div></div><a id="\Zend_Gdata_AuthSub::AUTHSUB_TOKEN_INFO_URI" class="anchor"></a><div class="constant publicC"><a href="#" class="gripper"><img src="../images/icons/arrow_right.png" alt="&gt;"></img><img src="../images/icons/arrow_down.png" alt="V" style="display: none;"></img></a><code class="title"><img src="../images/icons/constant.png" alt="Constant"></img> 
                <span class="highlight">AUTHSUB_TOKEN_INFO_URI</span>
                = 'https://www.google.com/accounts/AuthSubTokenInfo'</code><div class="description"></div><div class="code-tabs"></div><div class="clear"></div></div></div><h3>Methods</h3><div><a id="\Zend_Gdata_AuthSub::AuthSubRevokeToken()" class="anchor"></a><div class="method public"><a href="#" class="gripper"><img src="../images/icons/arrow_right.png"></img><img src="../images/icons/arrow_down.png" style="display: none;"></img></a><code class="title"><img src="../images/icons/method.png" alt="method" title="method"></img><img src="../images/icons/visibility_public.png" style="margin-right: 5px" alt="public"></img><span class="highlight">AuthSubRevokeToken</span><span class="nb-faded-text">(string $token, <a href="../files/Http.Client.html#\Zend_Http_Client">\Zend_Http_Client</a> $client = null, string $request_uri = self::AUTHSUB_REVOKE_TOKEN_URI)</span> : boolean</code><div class="description"><span class="attribute">static</span><p class="short_description">Revoke a token</p></div><div class="code-tabs"><div class="long-description"></div><strong>Parameters</strong><table class="argument-info"><thead><tr><th>Name</th><th>Type</th><th>Description</th></tr></thead><tr><th>$token</th><td>string</td><td><em><p>The token to revoke</p></em></td></tr><tr><th>$client</th><td><a href="../files/Http.Client.html#\Zend_Http_Client">\Zend_Http_Client</a></td><td><em><p>(optional) HTTP client to use to make the request</p>
</em></td></tr><tr><th>$request_uri</th><td>string</td><td><em><p>(optional) URI to which to direct the revokation request</p>
</em></td></tr></table><strong>Returns</strong><table class="argument-info"><thead><tr><th>Type</th><th>Description</th></tr></thead><tr><td>boolean</td><td>Whether the revokation was successful</td></tr></table><strong>Throws</strong><table class="argument-info"><thead><tr><th>Exception</th><th>Description</th></tr></thead><tr><td><a href="../files/Gdata.App.HttpException.html#\Zend_Gdata_App_HttpException">\Zend_Gdata_App_HttpException</a></td><td><em></em></td></tr></table></div><div class="clear"></div></div><a id="\Zend_Gdata_AuthSub::getAuthSubSessionToken()" class="anchor"></a><div class="method public"><a href="#" class="gripper"><img src="../images/icons/arrow_right.png"></img><img src="../images/icons/arrow_down.png" style="display: none;"></img></a><code class="title"><img src="../images/icons/method.png" alt="method" title="method"></img><img src="../images/icons/visibility_public.png" style="margin-right: 5px" alt="public"></img><span class="highlight">getAuthSubSessionToken</span><span class="nb-faded-text">(string $token, <a href="../files/Http.Client.html#\Zend_Http_Client">\Zend_Http_Client</a> $client = null, string $request_uri = self::AUTHSUB_SESSION_TOKEN_URI)</span> : string</code><div class="description"><span class="attribute">static</span><p class="short_description">Upgrades a single use token to a session token</p></div><div class="code-tabs"><div class="long-description"></div><strong>Parameters</strong><table class="argument-info"><thead><tr><th>Name</th><th>Type</th><th>Description</th></tr></thead><tr><th>$token</th><td>string</td><td><em><p>The single use token which is to be upgraded</p></em></td></tr><tr><th>$client</th><td><a href="../files/Http.Client.html#\Zend_Http_Client">\Zend_Http_Client</a></td><td><em><p>(optional) HTTP client to use to
                                make the request</p>
</em></td></tr><tr><th>$request_uri</th><td>string</td><td><em><p>(optional) URI to which to direct
                           the session token upgrade</p>
</em></td></tr></table><strong>Returns</strong><table class="argument-info"><thead><tr><th>Type</th><th>Description</th></tr></thead><tr><td>string</td><td>The upgraded token value</td></tr></table><strong>Throws</strong><table class="argument-info"><thead><tr><th>Exception</th><th>Description</th></tr></thead><tr><td><a href="../files/Gdata.App.AuthException.html#\Zend_Gdata_App_AuthException">\Zend_Gdata_App_AuthException</a></td><td><em></em></td></tr><tr><td><a href="../files/Gdata.App.HttpException.html#\Zend_Gdata_App_HttpException">\Zend_Gdata_App_HttpException</a></td><td><em></em></td></tr></table></div><div class="clear"></div></div><a id="\Zend_Gdata_AuthSub::getAuthSubTokenInfo()" class="anchor"></a><div class="method public"><a href="#" class="gripper"><img src="../images/icons/arrow_right.png"></img><img src="../images/icons/arrow_down.png" style="display: none;"></img></a><code class="title"><img src="../images/icons/method.png" alt="method" title="method"></img><img src="../images/icons/visibility_public.png" style="margin-right: 5px" alt="public"></img><span class="highlight">getAuthSubTokenInfo</span><span class="nb-faded-text">(string $token, <a href="../files/Http.Client.html#\Zend_Http_Client">\Zend_Http_Client</a> $client = null, string $request_uri = self::AUTHSUB_TOKEN_INFO_URI)</span> : void</code><div class="description"><span class="attribute">static</span><p class="short_description">get token information</p></div><div class="code-tabs"><div class="long-description"></div><strong>Parameters</strong><table class="argument-info"><thead><tr><th>Name</th><th>Type</th><th>Description</th></tr></thead><tr><th>$token</th><td>string</td><td><em><p>The token to retrieve information about</p></em></td></tr><tr><th>$client</th><td><a href="../files/Http.Client.html#\Zend_Http_Client">\Zend_Http_Client</a></td><td><em><p>(optional) HTTP client to use to
                                make the request</p>
</em></td></tr><tr><th>$request_uri</th><td>string</td><td><em><p>(optional) URI to which to direct
                           the information request</p>
</em></td></tr></table></div><div class="clear"></div></div><a id="\Zend_Gdata_AuthSub::getAuthSubTokenUri()" class="anchor"></a><div class="method public"><a href="#" class="gripper"><img src="../images/icons/arrow_right.png"></img><img src="../images/icons/arrow_down.png" style="display: none;"></img></a><code class="title"><img src="../images/icons/method.png" alt="method" title="method"></img><img src="../images/icons/visibility_public.png" style="margin-right: 5px" alt="public"></img><span class="highlight">getAuthSubTokenUri</span><span class="nb-faded-text">(string $next, string $scope, int $secure = 0, int $session = 0, string $request_uri = self::AUTHSUB_REQUEST_URI)</span> : void</code><div class="description"><span class="attribute">static</span><p class="short_description">Creates a URI to request a single-use AuthSub token.</p></div><div class="code-tabs"><div class="long-description"></div><strong>Parameters</strong><table class="argument-info"><thead><tr><th>Name</th><th>Type</th><th>Description</th></tr></thead><tr><th>$next</th><td>string</td><td><em><p>(required) URL identifying the service to be
                    accessed.
 The resulting token will enable access to the specified service only.
 Some services may limit scope further, such as read-only access.</p>
</em></td></tr><tr><th>$scope</th><td>string</td><td><em><p>(required) URL identifying the service to be
                     accessed.  The resulting token will enable
                     access to the specified service only.
                     Some services may limit scope further, such
                     as read-only access.</p>
</em></td></tr><tr><th>$secure</th><td>int</td><td><em><p>(optional) Boolean flag indicating whether the
                   authentication transaction should issue a secure
                   token (1) or a non-secure token (0). Secure tokens
                   are available to registered applications only.</p>
</em></td></tr><tr><th>$session</th><td>int</td><td><em><p>(optional) Boolean flag indicating whether
                    the one-time-use  token may be exchanged for
                    a session token (1) or not (0).</p>
</em></td></tr><tr><th>$request_uri</th><td>string</td><td><em><p>(optional) URI to which to direct the
                           authentication request.</p>
</em></td></tr></table></div><div class="clear"></div></div><a id="\Zend_Gdata_AuthSub::getHttpClient()" class="anchor"></a><div class="method public"><a href="#" class="gripper"><img src="../images/icons/arrow_right.png"></img><img src="../images/icons/arrow_down.png" style="display: none;"></img></a><code class="title"><img src="../images/icons/method.png" alt="method" title="method"></img><img src="../images/icons/visibility_public.png" style="margin-right: 5px" alt="public"></img><span class="highlight">getHttpClient</span><span class="nb-faded-text">(string $token, <a href="../files/Gdata.HttpClient.html#\Zend_Gdata_HttpClient">\Zend_Gdata_HttpClient</a> $client = null)</span> : void</code><div class="description"><span class="attribute">static</span><p class="short_description">Retrieve a HTTP client object with AuthSub credentials attached
as the Authorization header</p></div><div class="code-tabs"><div class="long-description"></div><strong>Parameters</strong><table class="argument-info"><thead><tr><th>Name</th><th>Type</th><th>Description</th></tr></thead><tr><th>$token</th><td>string</td><td><em><p>The token to retrieve information about</p></em></td></tr><tr><th>$client</th><td><a href="../files/Gdata.HttpClient.html#\Zend_Gdata_HttpClient">\Zend_Gdata_HttpClient</a></td><td><em><p>(optional) HTTP client to use to make the request</p>
</em></td></tr></table></div><div class="clear"></div></div></div></div></div><small class="footer">
            Documentation was generated by
            <a href="http://phpdoc.org">phpDocumentor
                2.0.0a12</a>.
        </small></body></html>