public class GitHubClient extends OAuth20Client<GitHubProfile>
This class is the OAuth client to authenticate users in GitHub.
The scope can be defined to require specific permissions from the user by using the setScope(String) method.
By default, the scope is: user.
It returns a GitHubProfile.
More information at http://developer.github.com/v3/users/
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
DEFAULT_SCOPE |
protected java.lang.String |
scope |
configurationATTEMPTED_AUTHENTICATION_SUFFIX, callbackUrl, urlResolverlogger| Constructor and Description |
|---|
GitHubClient() |
GitHubClient(java.lang.String key,
java.lang.String secret) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
clientInit(WebContext context) |
java.lang.String |
getScope() |
void |
setScope(java.lang.String scope) |
getConfiguration, getKey, getSecret, setConfiguration, setKey, setSecret, toStringcomputeFinalCallbackUrl, defaultLogoutActionBuilder, defaultRedirectActionBuilder, getAjaxRequestResolver, getCallbackUrl, getCallbackUrlResolver, getCredentials, getLogoutAction, getLogoutActionBuilder, getRedirectAction, getRedirectActionBuilder, getUrlResolver, internalInit, isIncludeClientNameInCallbackUrl, redirect, setAjaxRequestResolver, setCallbackUrl, setCallbackUrlResolver, setIncludeClientNameInCallbackUrl, setLogoutActionBuilder, setRedirectActionBuilder, setUrlResolveraddAuthorizationGenerator, addAuthorizationGenerators, defaultAuthenticator, defaultCredentialsExtractor, defaultProfileCreator, getAuthenticator, getAuthorizationGenerators, getCredentialsExtractor, getName, getProfileCreator, getUserProfile, notifySessionRenewal, retrieveCredentials, retrieveUserProfile, setAuthenticator, setAuthorizationGenerator, setAuthorizationGenerators, setAuthorizationGenerators, setCredentialsExtractor, setName, setProfileCreatorinit, reinitpublic static final java.lang.String DEFAULT_SCOPE
protected java.lang.String scope
public GitHubClient()
public GitHubClient(java.lang.String key,
java.lang.String secret)
protected void clientInit(WebContext context)
clientInit in class OAuth20Client<GitHubProfile>public java.lang.String getScope()
public void setScope(java.lang.String scope)
Copyright © 2018. All Rights Reserved.