mirror of
				https://github.com/elyby/oauth2-server.git
				synced 2025-05-31 14:12:07 +05:30 
			
		
		
		
	Removed type hints and changed the name of the class
This commit is contained in:
		| @@ -22,43 +22,43 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. | |||||||
|  |  | ||||||
| namespace oauth2server; | namespace oauth2server; | ||||||
|  |  | ||||||
| interface OAuth2ServerDatabase | interface DatabaseInteface | ||||||
| { | { | ||||||
|     public function validateClient( |     public function validateClient( | ||||||
|         string $clientId, |         $clientId, | ||||||
|         string $clientSecret = null, |         $clientSecret, | ||||||
|         string $redirectUri = null |         $redirectUri | ||||||
|     ); |     ); | ||||||
|  |  | ||||||
|     public function newSession( |     public function newSession( | ||||||
|         string $clientId, |         $clientId, | ||||||
|         string $redirectUri, |         $redirectUri, | ||||||
|         $type = 'user', |         $type = 'user', | ||||||
|         string $typeId = null, |         $typeId = null, | ||||||
|         string $authCode = null, |         $authCode = null, | ||||||
|         string $accessToken = null, |         $accessToken = null, | ||||||
|         $stage = 'request' |         $stage = 'request' | ||||||
|     ); |     ); | ||||||
|  |  | ||||||
|     public function updateSession( |     public function updateSession( | ||||||
|         string $clientId, |         $clientId, | ||||||
|         $type = 'user', |         $type = 'user', | ||||||
|         string $typeId = null, |         $typeId = null, | ||||||
|         string $authCode = null, |         $authCode = null, | ||||||
|         string $accessToken = null, |         $accessToken = null, | ||||||
|         string $stage |         $stage | ||||||
|     ); |     ); | ||||||
|  |  | ||||||
|     public function deleteSession( |     public function deleteSession( | ||||||
|         string $clientId, |         $clientId, | ||||||
|         string $type, |         $type, | ||||||
|         string $typeId |         $typeId | ||||||
|     ); |     ); | ||||||
|  |  | ||||||
|     public function validateAuthCode( |     public function validateAuthCode( | ||||||
|         string $clientId, |         $clientId, | ||||||
|         string $redirectUri, |         $redirectUri, | ||||||
|         string $authCode |         $authCode | ||||||
|     ); |     ); | ||||||
|  |  | ||||||
|     /** |     /** | ||||||
| @@ -67,34 +67,34 @@ interface OAuth2ServerDatabase | |||||||
|      * Check if an access token exists for a user (or an application) |      * Check if an access token exists for a user (or an application) | ||||||
|      *  |      *  | ||||||
|      * @access public |      * @access public | ||||||
|      * @return bool|string Return FALSE is a token doesn't exist or return the  |      * @return bool|Return FALSE is a token doesn't exist or return the  | ||||||
|      * access token as a string |      * access token as a string | ||||||
|      */ |      */ | ||||||
|     public function hasAccessToken( |     public function hasAccessToken( | ||||||
|         string $typeId, |         $typeId, | ||||||
|         string $clientId |         $clientId | ||||||
|     ); |     ); | ||||||
|  |  | ||||||
|     public function getAccessToken(int $sessionId); |     public function getAccessToken($sessionId); | ||||||
|  |  | ||||||
|     public function removeAuthCode(int $sessionId); |     public function removeAuthCode($sessionId); | ||||||
|  |  | ||||||
|     public function setAccessToken( |     public function setAccessToken( | ||||||
|         int $sessionId, |         $sessionId, | ||||||
|         string $accessToken |         $accessToken | ||||||
|     ); |     ); | ||||||
|  |  | ||||||
|     public function addSessionScope( |     public function addSessionScope( | ||||||
|         int $sessionId, |         $sessionId, | ||||||
|         string $scope |         $scope | ||||||
|     ); |     ); | ||||||
|  |  | ||||||
|     public function getScope(string $scope); |     public function getScope($scope); | ||||||
|  |  | ||||||
|     public function updateSessionScopeAccessToken( |     public function updateSessionScopeAccessToken( | ||||||
|         int $sesstionId, |         $sesstionId, | ||||||
|         string $accessToken |         $accessToken | ||||||
|     ); |     ); | ||||||
|  |  | ||||||
|     public function accessTokenScopes(string $accessToken); |     public function accessTokenScopes($accessToken); | ||||||
| } | } | ||||||
		Reference in New Issue
	
	Block a user