oauth2-server/src/Storage/ScopeInterface.php

34 lines
817 B
PHP
Raw Normal View History

2012-12-28 15:12:16 -05:00
<?php
2013-02-13 19:59:08 +00:00
/**
* OAuth 2.0 Scope storage interface
*
2014-01-08 16:15:29 +00:00
* @package league/oauth2-server
2013-02-13 19:59:08 +00:00
* @author Alex Bilbie <hello@alexbilbie.com>
2014-03-09 19:34:23 +00:00
* @copyright Copyright (c) Alex Bilbie
2013-02-13 19:59:08 +00:00
* @license http://mit-license.org/
2014-03-09 20:05:38 +00:00
* @link https://github.com/thephpleague/oauth2-server
2013-02-13 19:59:08 +00:00
*/
2012-12-28 15:12:16 -05:00
namespace League\OAuth2\Server\Storage;
2012-12-28 15:12:16 -05:00
2014-01-08 16:15:29 +00:00
/**
* Scope interface
*/
2012-12-28 15:12:16 -05:00
interface ScopeInterface
{
2013-01-29 14:25:49 +00:00
/**
* Return information about a scope
*
* Example SQL query:
*
* <code>
* SELECT * FROM oauth_scopes WHERE scope = :scope
2013-01-29 14:25:49 +00:00
* </code>
*
* @param string $scope The scope
2013-05-14 08:59:53 +01:00
* @param string $grantType The grant type used in the request (default = "null")
2014-05-02 15:14:12 +01:00
* @return \League\OAuth2\Server\Entity\ScopeEntity
2013-01-29 14:25:49 +00:00
*/
2014-01-10 12:30:13 +00:00
public function get($scope, $grantType = null);
2012-12-28 15:12:16 -05:00
}