public class FoursquareProfileDefinition extends OAuth20ProfileDefinition<FoursquareProfile>
Modifier and Type | Field and Description |
---|---|
static String |
BIO |
static String |
CONTACT |
static String |
FIRENDS |
static String |
FIRST_NAME |
static String |
HOME_CITY |
static String |
LAST_NAME |
static String |
PHOTO |
DISPLAY_NAME, EMAIL, FAMILY_NAME, GENDER, LOCALE, LOCATION, PICTURE_URL, PROFILE_URL
logger, newProfile
Constructor and Description |
---|
FoursquareProfileDefinition() |
Modifier and Type | Method and Description |
---|---|
FoursquareProfile |
extractUserProfile(String body)
Extract the user profile from the response (JSON, XML...) of the profile url.
|
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, getConverters, getPrimaryAttributes, getSecondaryAttributes, newProfile, primary, secondary, setProfileFactory
public static final String FIRST_NAME
public static final String LAST_NAME
public static final String PHOTO
public static final String FIRENDS
public static final String HOME_CITY
public static final String CONTACT
public static final String BIO
public String getProfileUrl(com.github.scribejava.core.model.OAuth2AccessToken accessToken, OAuth20Configuration configuration)
OAuthProfileDefinition
getProfileUrl
in class OAuthProfileDefinition<FoursquareProfile,com.github.scribejava.core.model.OAuth2AccessToken,OAuth20Configuration>
accessToken
- only used when constructing dynamic urls from data in the tokenconfiguration
- the current configurationpublic FoursquareProfile extractUserProfile(String body) throws HttpAction
OAuthProfileDefinition
extractUserProfile
in class OAuthProfileDefinition<FoursquareProfile,com.github.scribejava.core.model.OAuth2AccessToken,OAuth20Configuration>
body
- the response bodyHttpAction
- whether an extra HTTP action is requiredCopyright © 2017. All rights reserved.