public abstract class DelegationService extends Object implements Server
Generally applications will write to this to get their functionality and only in exceptional cases will use the implementations of the underlying service. Direct references to protocols (e.g. OAuth 1.0a) are inherently fragile and will break at some point, e.g. when trying to use OAuth 2.0. One of the strongest arguments for doing it this way is that services may have to support several types of requests (OAuth 1 and 2) and this design allows for keeping multiple instances cleanly separated.
Created by Jeff Gaynor
on Apr 4, 2011 at 3:51:41 PM
Modifier | Constructor and Description |
---|---|
protected |
DelegationService(AGServer agServer,
ATServer atServer,
PAServer paServer) |
Modifier and Type | Method and Description |
---|---|
abstract URI |
createRedirectURL(DelegationRequest delegationAssetRequest,
AGResponse agResp) |
AGServer |
getAgServer()
This server issues the authorization grant that starts the delegation process.
|
protected ATResponse |
getAT(AuthorizationGrant grant,
Client client,
Map<String,String> parameters) |
protected ATResponse |
getAT(AuthorizationGrant grant,
Verifier v,
Client client,
Map<String,String> parameters) |
ATResponse |
getAT(DelegatedAssetRequest delegationAssetRequest) |
ATServer |
getAtServer()
The authorization server.
|
DelegatedAssetResponse |
getCert(ATResponse atResponse,
Client client,
Map<String,String> assetParameters) |
PAServer |
getPaServer()
The resource server.
|
Response |
process(Request request) |
DelegatedAssetResponse |
processAssetRequest(DelegatedAssetRequest delegationAssetRequest)
Gets the asset once the delegation has been approved.
|
DelegationResponse |
processDelegationRequest(DelegationRequest delegationRequest)
Starts the delegation process.
|
public DelegationResponse processDelegationRequest(DelegationRequest delegationRequest)
protected ATResponse getAT(AuthorizationGrant grant, Client client, Map<String,String> parameters)
protected ATResponse getAT(AuthorizationGrant grant, Verifier v, Client client, Map<String,String> parameters)
public ATResponse getAT(DelegatedAssetRequest delegationAssetRequest)
public DelegatedAssetResponse processAssetRequest(DelegatedAssetRequest delegationAssetRequest)
public DelegatedAssetResponse getCert(ATResponse atResponse, Client client, Map<String,String> assetParameters)
public abstract URI createRedirectURL(DelegationRequest delegationAssetRequest, AGResponse agResp)
public ATServer getAtServer()
public PAServer getPaServer()
public AGServer getAgServer()
Copyright © 2019. All Rights Reserved.