Class AuthorizationCodeGrant
- java.lang.Object
-
- org.apache.cxf.rs.security.oauth2.grants.code.AuthorizationCodeGrant
-
- All Implemented Interfaces:
Serializable,AccessTokenGrant
- Direct Known Subclasses:
JwtRequestCodeGrant,ServerAuthorizationCodeGrant
@MappedSuperclass public class AuthorizationCodeGrant extends Object implements AccessTokenGrant
Base Authorization Code Grant representation, captures the code and the redirect URI this code has been returned to, visible to the client- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description AuthorizationCodeGrant()AuthorizationCodeGrant(String code)AuthorizationCodeGrant(String code, URI uri)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetCode()Gets the authorization codeStringgetCodeVerifier()StringgetRedirectUri()Gets the redirect URIStringgetType()Returns the token grant type, example, "authorization_code"voidsetCode(String c)voidsetCodeVerifier(String codeVerifier)voidsetRedirectUri(String redirectUri)Sets the redirect URI, if set then the client is expected to include the same URI during the access token requestjavax.ws.rs.core.MultivaluedMap<String,String>toMap()Returns the map containing public grant parameters; can be used by clients requesting the access tokens.
-
-
-
Method Detail
-
setRedirectUri
public void setRedirectUri(String redirectUri)
Sets the redirect URI, if set then the client is expected to include the same URI during the access token request- Parameters:
redirectUri- redirect URI
-
getRedirectUri
public String getRedirectUri()
Gets the redirect URI- Returns:
- the redirect URI
-
getCode
public String getCode()
Gets the authorization code- Returns:
- the code
-
setCode
public void setCode(String c)
-
getType
public String getType()
Returns the token grant type, example, "authorization_code"- Specified by:
getTypein interfaceAccessTokenGrant- Returns:
- the grant type
-
toMap
public javax.ws.rs.core.MultivaluedMap<String,String> toMap()
Returns the map containing public grant parameters; can be used by clients requesting the access tokens.- Specified by:
toMapin interfaceAccessTokenGrant- Returns:
- the grant parameters
-
getCodeVerifier
public String getCodeVerifier()
-
setCodeVerifier
public void setCodeVerifier(String codeVerifier)
-
-