Cheetah
Public Member Functions | List of all members
OAuth2\Storage\ScopeInterface Interface Reference
Inheritance diagram for OAuth2\Storage\ScopeInterface:
OAuth2\ScopeInterface OAuth2\Storage\Cassandra OAuth2\Storage\DynamoDB OAuth2\Storage\Memory OAuth2\Storage\Pdo OAuth2\Storage\Redis OAuth2\Scope

Public Member Functions

 scopeExists ($scope)
 
 getDefaultScope ($client_id=null)
 

Detailed Description

Implement this interface to specify where the OAuth2 Server should retrieve data involving the relevent scopes associated with this implementation.

Author
Brent Shaffer <bshafs at gmail dot com>

Definition at line 12 of file ScopeInterface.php.

Member Function Documentation

◆ getDefaultScope()

OAuth2\Storage\ScopeInterface::getDefaultScope (   $client_id = null)

The default scope to use in the event the client does not request one. By returning "false", a request_error is returned by the server to force a scope request by the client. By returning "null", opt out of requiring scopes

Parameters
$client_idAn optional client id that can be used to return customized default scopes.
Returns
string representation of default scope, null if scopes are not defined, or false to force scope request by the client

ex: 'default' ex: null

Implemented in OAuth2\Storage\Redis, OAuth2\Storage\Pdo, OAuth2\Storage\Memory, OAuth2\Storage\DynamoDB, OAuth2\Storage\Cassandra, and OAuth2\Scope.

◆ scopeExists()

OAuth2\Storage\ScopeInterface::scopeExists (   $scope)

Check if the provided scope exists.

Parameters
$scopeA space-separated string of scopes.
Returns
TRUE if it exists, FALSE otherwise.

Implemented in OAuth2\Storage\Redis, OAuth2\Storage\Pdo, OAuth2\Storage\Memory, OAuth2\Storage\DynamoDB, OAuth2\Storage\Cassandra, and OAuth2\Scope.


The documentation for this interface was generated from the following file: