public abstract class RandomValueAuthorizationCodeServices extends Object implements AuthorizationCodeServices
Constructor and Description |
---|
RandomValueAuthorizationCodeServices() |
Modifier and Type | Method and Description |
---|---|
OAuth2Authentication |
consumeAuthorizationCode(String code)
Consume a authorization code.
|
String |
createAuthorizationCode(OAuth2Authentication authentication)
Create a authorization code for the specified authentications.
|
protected abstract OAuth2Authentication |
remove(String code) |
protected abstract void |
store(String code,
OAuth2Authentication authentication) |
public RandomValueAuthorizationCodeServices()
protected abstract void store(String code, OAuth2Authentication authentication)
protected abstract OAuth2Authentication remove(String code)
public String createAuthorizationCode(OAuth2Authentication authentication)
AuthorizationCodeServices
createAuthorizationCode
in interface AuthorizationCodeServices
authentication
- The authentications to store.public OAuth2Authentication consumeAuthorizationCode(String code) throws InvalidGrantException
AuthorizationCodeServices
consumeAuthorizationCode
in interface AuthorizationCodeServices
code
- The authorization code to consume.InvalidGrantException
- If the authorization code is invalid or expired.Copyright © 2019. All rights reserved.