public class OpenIdImpl extends AbstractProvider implements AuthProvider, Serializable
COUNTRY, DOB, EMAIL, EXT_NAMESPACE, FIRST_NAME, FULL_NAME, GENDER, LANGUAGE, LAST_NAME, NICK_NAME, POSTCODE| Constructor and Description |
|---|
OpenIdImpl(OAuthConfig config) |
OpenIdImpl(Properties props) |
| Modifier and Type | Method and Description |
|---|---|
Response |
api(String url,
String methodType,
Map<String,String> params,
Map<String,String> headerParams,
String body)
Not implemented for OpenId provider.
|
AccessGrant |
getAccessGrant()
Retrieves the AccessGrant object.
|
List<Contact> |
getContactList()
Contact list is not available for generic Open ID providers.
|
String |
getLoginRedirectURL(String successUrl)
This is the most important action.
|
protected OAuthStrategyBase |
getOauthStrategy()
Returns the OAuthStrategyBase of a provider.
|
protected List<String> |
getPluginsList()
Returns the list of plugins of a provider.
|
String |
getProviderId()
Retrieves the provider id
|
Profile |
getUserProfile()
Retrieves the user profile.
|
void |
logout()
Logout
|
void |
setAccessGrant(AccessGrant accessGrant)
Stores access grant for the provider *
|
void |
setPermission(Permission p) |
Response |
updateStatus(String msg)
Updating status is not available for generic Open ID providers.
|
Response |
uploadImage(String message,
String fileName,
InputStream inputStream)
Updates the image and message on the chosen provider if available.
|
Profile |
verifyResponse(Map<String,String> requestParams)
Verifies the user when the external provider redirects back to our
application.
|
getPlugin, getPluginsScope, isSupportedPlugin, refreshToken, registerPluginsclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetPlugin, isSupportedPlugin, refreshToken, registerPluginspublic OpenIdImpl(Properties props) throws org.openid4java.consumer.ConsumerException, Exception
org.openid4java.consumer.ConsumerExceptionExceptionpublic OpenIdImpl(OAuthConfig config) throws org.openid4java.consumer.ConsumerException, Exception
org.openid4java.consumer.ConsumerExceptionExceptionpublic void setAccessGrant(AccessGrant accessGrant) throws AccessTokenExpireException
AuthProvidersetAccessGrant in interface AuthProvideraccessGrant - It contains the access token and other informationAccessTokenExpireExceptionpublic String getLoginRedirectURL(String successUrl) throws IOException
getLoginRedirectURL in interface AuthProviderExceptionIOExceptionpublic Profile verifyResponse(Map<String,String> requestParams) throws Exception
verifyResponse in interface AuthProviderrequestParams - request parameters, received from the providerExceptionpublic Response updateStatus(String msg) throws Exception
updateStatus in interface AuthProvidermsg - Message to be shown as user's statusExceptionpublic List<Contact> getContactList()
getContactList in interface AuthProviderpublic void logout()
logout in interface AuthProviderpublic void setPermission(Permission p)
setPermission in interface AuthProviderp - Permission object which can be Permission.AUHTHENTICATE_ONLY,
Permission.ALL, Permission.DEFAULTpublic Response api(String url, String methodType, Map<String,String> params, Map<String,String> headerParams, String body) throws Exception
api in interface AuthProviderurl - methodType - params - headerParams - body - Exceptionpublic Profile getUserProfile()
getUserProfile in interface AuthProviderpublic AccessGrant getAccessGrant()
AuthProvidergetAccessGrant in interface AuthProviderpublic String getProviderId()
AuthProvidergetProviderId in interface AuthProviderpublic Response uploadImage(String message, String fileName, InputStream inputStream) throws Exception
AuthProvideruploadImage in interface AuthProvidermessage - Status MessagefileName - Image file nameinputStream - Input Stream of imageExceptionprotected OAuthStrategyBase getOauthStrategy()
AbstractProvidergetOauthStrategy in class AbstractProviderprotected List<String> getPluginsList()
AbstractProvidergetPluginsList in class AbstractProviderCopyright © 2018. All Rights Reserved.