Apache CXF API

org.apache.cxf.rs.security.oauth2.grants
Class AbstractGrant

java.lang.Object
  extended by org.apache.cxf.rs.security.oauth2.grants.AbstractGrant
All Implemented Interfaces:
Serializable, AccessTokenGrant
Direct Known Subclasses:
ClientCredentialsGrant, ResourceOwnerGrant

public abstract class AbstractGrant
extends Object
implements AccessTokenGrant

Abstract access token grant

See Also:
Serialized Form

Constructor Summary
protected AbstractGrant(String grantType)
           
protected AbstractGrant(String grantType, String scope)
           
protected AbstractGrant(String grantType, String scope, String audience)
           
 
Method Summary
 String getType()
          Returns the token grant type, example, "authorization_code"
 void setAudience(String audience)
           
 javax.ws.rs.core.MultivaluedMap<String,String> toMap()
          Returns the map containing public grant parameters; can be used by clients requesting the access tokens.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractGrant

protected AbstractGrant(String grantType)

AbstractGrant

protected AbstractGrant(String grantType,
                        String scope)

AbstractGrant

protected AbstractGrant(String grantType,
                        String scope,
                        String audience)
Method Detail

getType

public String getType()
Description copied from interface: AccessTokenGrant
Returns the token grant type, example, "authorization_code"

Specified by:
getType in interface AccessTokenGrant
Returns:
the grant type

setAudience

public void setAudience(String audience)

toMap

public javax.ws.rs.core.MultivaluedMap<String,String> toMap()
Description copied from interface: AccessTokenGrant
Returns the map containing public grant parameters; can be used by clients requesting the access tokens.

Specified by:
toMap in interface AccessTokenGrant
Returns:
the grant parameters

Apache CXF API

Apache CXF