public class StravaProfile extends OAuth20Profile
Encapsulates a Strava athlete profile.
Exemple of a json sent by Strava: { "id": 1321007, "resource_state": 3, "firstname": "Adrian", "lastname": "Papusoi", "profile_medium": "http:\/\/dgalywyr863hv.cloudfront.net\/pictures\/athletes\/1321007\/361713\/1\/medium.jpg", "profile": "http:\/\/dgalywyr863hv.cloudfront.net\/pictures\/athletes\/1321007\/361713\/1\/large.jpg", "city": "Courbevoie", "state": "Île-de-France", "country": "France", "sex": "M", "friend": null, "follower": null, "premium": false, "created_at": "2012-11-13T10:13:38Z", "updated_at": "2014-12-17T13:30:39Z", "badge_type_id": 0, "follower_count": 24, "friend_count": 30, "mutual_friend_count": 0, "date_preference": "%d\/%m\/%Y", "measurement_preference": "meters", "email": "[email protected]", "ftp": null, "clubs": [ { "id": 37365, "resource_state": 2, "name": "Amicale Cycliste des Baltringues de Longchamp", "profile_medium": "http:\/\/dgalywyr863hv.cloudfront.net\/pictures\/clubs\/37365\/1022943\/1\/medium.jpg", "profile": "http:\/\/dgalywyr863hv.cloudfront.net\/pictures\/clubs\/37365\/1022943\/1\/large.jpg" }, { "id": 45060, "resource_state": 2, "name": "VeloViewer", "profile_medium": "http:\/\/dgalywyr863hv.cloudfront.net\/pictures\/clubs\/45060\/1141016\/3\/medium.jpg", "profile": "http:\/\/dgalywyr863hv.cloudfront.net\/pictures\/clubs\/45060\/1141016\/3\/large.jpg" }, { "id": 21017, "resource_state": 2, "name": "Paris cycling meetup group", "profile_medium": "http:\/\/dgalywyr863hv.cloudfront.net\/pictures\/clubs\/21017\/449495\/1\/medium.jpg", "profile": "http:\/\/dgalywyr863hv.cloudfront.net\/pictures\/clubs\/21017\/449495\/1\/large.jpg" } ], "bikes": [ { "id": "b1232920", "primary": false, "name": "BH G5", "resource_state": 2, "distance": 4587858 }, { "id": "b662369", "primary": false, "name": "Gitane '80s", "resource_state": 2, "distance": 371587 }, { "id": "b526413", "primary": false, "name": "Grand Canyon AL 6.0", "resource_state": 2, "distance": 362774 }, { "id": "b1534132", "primary": true, "name": "Kona Dr Good", "resource_state": 2, "distance": 1303618 } ], "shoes": [ ] }USERNAME
logger, SEPARATOR
Constructor and Description |
---|
StravaProfile() |
Modifier and Type | Method and Description |
---|---|
protected AttributesDefinition |
getAttributesDefinition()
Return the attributes definition for this user profile.
|
List<StravaGear> |
getBikes() |
List<StravaClub> |
getClubs() |
String |
getCountry() |
Date |
getCreatedAt() |
String |
getDatePreference() |
String |
getDisplayName()
Return the displayed name of the user.
|
String |
getEmail()
Return the email of the user.
|
String |
getFamilyName()
Return the family name of the user.
|
String |
getFirstName()
Return the first name of the user.
|
Integer |
getFollowerCount() |
Integer |
getFriendCount() |
Gender |
getGender()
Return the gender of the user.
|
String |
getLocation()
Return the location of the user.
|
String |
getMeasurementPreference() |
String |
getPictureUrl()
Return the url of the picture of the user.
|
String |
getProfileMedium() |
String |
getProfileUrl()
Return the url of the profile of the user.
|
Integer |
getResourceState() |
List<StravaGear> |
getShoes() |
String |
getState() |
Date |
getUpdatedAt() |
Boolean |
isPremium() |
clear, getAccessToken, setAccessToken
getLocale, getUsername
addAttribute, addAttributes, addPermission, addPermissions, addRole, addRoles, build, getAttribute, getAttribute, getAttributes, getId, getPermissions, getRoles, getTypedId, isRemembered, readExternal, setId, setRemembered, toString, writeExternal
protected AttributesDefinition getAttributesDefinition()
UserProfile
getAttributesDefinition
in class UserProfile
public String getFirstName()
CommonProfile
getFirstName
in class CommonProfile
public String getFamilyName()
CommonProfile
getFamilyName
in class CommonProfile
public String getDisplayName()
CommonProfile
getDisplayName
in class CommonProfile
public String getEmail()
CommonProfile
getEmail
in class CommonProfile
public String getPictureUrl()
CommonProfile
getPictureUrl
in class CommonProfile
public String getProfileUrl()
CommonProfile
getProfileUrl
in class CommonProfile
public String getLocation()
CommonProfile
getLocation
in class CommonProfile
public Gender getGender()
CommonProfile
getGender
in class CommonProfile
public Integer getResourceState()
public String getProfileMedium()
public String getState()
public String getCountry()
public Boolean isPremium()
public Date getCreatedAt()
public Date getUpdatedAt()
public Integer getFollowerCount()
public Integer getFriendCount()
public String getDatePreference()
public String getMeasurementPreference()
public List<StravaGear> getBikes()
public List<StravaGear> getShoes()
public List<StravaClub> getClubs()
Copyright © 2016. All rights reserved.