public class OpenConextOAuthClientImpl extends Object implements OpenConextOAuthClient, org.springframework.beans.factory.InitializingBean
| Constructor and Description |
|---|
OpenConextOAuthClientImpl() |
| Modifier and Type | Method and Description |
|---|---|
void |
afterPropertiesSet() |
String |
getAuthorizationUrl()
Get the authorization url
|
void |
getClientAccessToken() |
Group20 |
getGroup20(String userId,
String groupId,
String onBehalfOf)
Get group information about the given group, for the given user.
|
List<Person> |
getGroupMembers(String groupId,
String onBehalfOf)
Get the group members of the given group.
|
List<Group> |
getGroups(String userId,
String onBehalfOf)
Get Persons' Groups
|
List<Group20> |
getGroups20(String userId,
String onBehalfOf)
Get Persons' Groups
|
Person |
getPerson(String userId,
String onBehalfOf)
Get the OpenSocial Person.
|
boolean |
isAccessTokenGranted(String userId)
Is it possible to make OpenSocial requests for this user (as onBehalfOf).
|
void |
oauthCallback(javax.servlet.http.HttpServletRequest request,
String onBehalfOf)
Clients who have requested a redirect to the authorization URL will be
notified on the registered callback URL.
|
void |
setCallbackUrl(String url) |
void |
setConsumerKey(String key) |
void |
setConsumerSecret(String secret) |
void |
setEndpointBaseUrl(String url) |
void |
setRepository(OAuthRepository repository) |
void |
setVersion(OAuthVersion v) |
public boolean isAccessTokenGranted(String userId)
OpenConextOAuthClientisAccessTokenGranted in interface OpenConextOAuthClientuserId - the unique identifierpublic String getAuthorizationUrl()
OpenConextOAuthClientgetAuthorizationUrl in interface OpenConextOAuthClientpublic void oauthCallback(javax.servlet.http.HttpServletRequest request,
String onBehalfOf)
OpenConextOAuthClientoauthCallback in interface OpenConextOAuthClientrequest - the HTTP request for obtaining the request tokenonBehalfOf - the userId of the end userpublic Person getPerson(String userId, String onBehalfOf)
OpenConextOAuthClientgetPerson in interface OpenConextOAuthClientuserId - the unique identifieronBehalfOf - the unique identifier of the user that is going to make the
requestPersonpublic List<Person> getGroupMembers(String groupId, String onBehalfOf)
OpenConextOAuthClientgetGroupMembers in interface OpenConextOAuthClientgroupId - String the unique identifier for the grouponBehalfOf - String the unique identifier of the user that is going to
make the requestArrayList containing Person'spublic List<Group> getGroups(String userId, String onBehalfOf)
OpenConextOAuthClientgetGroups in interface OpenConextOAuthClientuserId - the unique identifieronBehalfOf - the unique identifier of the user that is going to make the
requestList containing the Groupspublic List<Group20> getGroups20(String userId, String onBehalfOf)
OpenConextOAuthClientgetGroups20 in interface OpenConextOAuthClientuserId - the unique identifieronBehalfOf - the unique identifier of the user that is going to make the
requestList containing the Groupspublic Group20 getGroup20(String userId, String groupId, String onBehalfOf)
OpenConextOAuthClientgetGroup20 in interface OpenConextOAuthClientuserId - the userId that is a member of the given groupgroupId - the groupId of the grouponBehalfOf - id of the end user on whose behalf this call is done.public void setCallbackUrl(String url)
public void setConsumerSecret(String secret)
public void setConsumerKey(String key)
public void setEndpointBaseUrl(String url)
public void setVersion(OAuthVersion v)
public void afterPropertiesSet()
throws Exception
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBeanExceptionpublic void setRepository(OAuthRepository repository)
public void getClientAccessToken()
Copyright © 2009–2014 SURFnet bv, The Netherlands. All rights reserved.