public class OkProfileDefinition extends OAuth20ProfileDefinition<OkProfile>
Modifier and Type | Field and Description |
---|---|
static String |
AGE |
static String |
BIRTHDAY |
static String |
CURRENT_STATUS |
static String |
CURRENT_STATUS_DATE |
static String |
CURRENT_STATUS_ID |
static String |
HAS_EMAIL |
static String |
LAST_NAME |
static String |
LOCATION_CITY |
static String |
LOCATION_COUNTRY |
static String |
LOCATION_COUNTRY_CODE |
static String |
LOCATION_COUNTRY_NAME |
static String |
NAME |
static String |
ONLINE |
static String |
PIC_1 |
static String |
PIC_2 |
static String |
UID |
DISPLAY_NAME, EMAIL, FAMILY_NAME, FIRST_NAME, GENDER, LOCALE, LOCATION, PICTURE_URL, PROFILE_URL
logger, newProfile
Constructor and Description |
---|
OkProfileDefinition() |
Modifier and Type | Method and Description |
---|---|
OkProfile |
extractUserProfile(String body)
Extract the user profile from the response (JSON, XML...) of the profile url.
|
protected String |
getMD5SignAsHexString(String strForEncoding) |
String |
getProfileUrl(com.github.scribejava.core.model.OAuth2AccessToken accessToken,
OAuth20Configuration configuration)
Retrieve the url of the profile of the authenticated user for the provider.
|
getProfileVerb
convertAndAdd, convertAndAdd, convertAndAdd, convertAndAdd, getConverters, getPrimaryAttributes, getSecondaryAttributes, newProfile, primary, secondary, setProfileFactory
public static final String UID
public static final String BIRTHDAY
public static final String AGE
public static final String NAME
public static final String LOCATION_CITY
public static final String LOCATION_COUNTRY
public static final String LOCATION_COUNTRY_CODE
public static final String LOCATION_COUNTRY_NAME
public static final String ONLINE
public static final String LAST_NAME
public static final String HAS_EMAIL
public static final String CURRENT_STATUS
public static final String CURRENT_STATUS_ID
public static final String CURRENT_STATUS_DATE
public static final String PIC_1
public static final String PIC_2
public String getProfileUrl(com.github.scribejava.core.model.OAuth2AccessToken accessToken, OAuth20Configuration configuration)
OAuthProfileDefinition
getProfileUrl
in class OAuthProfileDefinition<OkProfile,com.github.scribejava.core.model.OAuth2AccessToken,OAuth20Configuration>
accessToken
- only used when constructing dynamic urls from data in the tokenconfiguration
- the current configurationprotected String getMD5SignAsHexString(String strForEncoding) throws NoSuchAlgorithmException, UnsupportedEncodingException
public OkProfile extractUserProfile(String body) throws HttpAction
OAuthProfileDefinition
extractUserProfile
in class OAuthProfileDefinition<OkProfile,com.github.scribejava.core.model.OAuth2AccessToken,OAuth20Configuration>
body
- the response bodyHttpAction
- whether an extra HTTP action is requiredCopyright © 2018. All rights reserved.