public static class OAuthSession.Builder extends Object
OAuthSession| Constructor and Description |
|---|
OAuthSession.Builder() |
| Modifier and Type | Method and Description |
|---|---|
OAuthSession.Builder |
accessToken(Token accessToken)
Set the OAuth Access token for the session
|
OAuthSession |
build()
Build the
OAuthSession |
OAuthSession.Builder |
id(String id)
Set the id for the session to build.
|
OAuthSession.Builder |
providerName(String providerName)
Set the provider qualifier for the session from the provider name
|
OAuthSession.Builder |
qualifier(Annotation qualifier)
Set the provider qualifier for the session
|
OAuthSession.Builder |
readFromOAuthSession(OAuthSession session)
Configure this builder with an existing
OAuthSession. |
OAuthSession.Builder |
repo(UserSessionRepository repo)
Set the User Repository which contains the session to build
|
OAuthSession.Builder |
requestToken(Token requestToken)
Set the OAuth Request Token for the session
|
OAuthSession.Builder |
userProfile(UserProfile userProfile)
Set the user profile link to the session to build.
|
OAuthSession.Builder |
verifier(String verifier)
Set the OAuth Verifier (OAuth 1.0a) or Code (OAuth 2.0a) returned by the provider in the callback
|
public OAuthSession.Builder providerName(String providerName) throws ProviderMismatchException
providerName - linked to a ProviderRelated qualifierProviderMismatchException - if parameter is null or if no provider exists for this namepublic OAuthSession.Builder qualifier(Annotation qualifier) throws ProviderMismatchException
qualifier - with ProviderRelated meta-annotationProviderMismatchException - if parameter is null or if no provider exists for this qualifierpublic OAuthSession.Builder requestToken(Token requestToken)
requestToken - the request Token to setpublic OAuthSession.Builder accessToken(Token accessToken)
accessToken - the access Token to setpublic OAuthSession.Builder verifier(String verifier)
verifier - the verifier to setpublic OAuthSession.Builder userProfile(UserProfile userProfile)
userProfile - the User Profile to setpublic OAuthSession.Builder repo(UserSessionRepository repo)
repo - the repository that will contain this sessionpublic OAuthSession.Builder id(String id)
id - the id to setpublic OAuthSession.Builder readFromOAuthSession(OAuthSession session)
OAuthSession. Convenient to clone a session
or to create an unproxified version of a sessionsession - the session to read values frompublic OAuthSession build()
OAuthSessionCopyright © 2012-2013. All Rights Reserved.