public enum StravaAgeGroup extends Enum<StravaAgeGroup> implements StravaReferenceType<String>
Age group ranges used to generate filtered segment leaderboards
| Enum Constant and Description |
|---|
AGE0_24
Age 0-24
|
AGE25_34
Age 25-34
|
AGE35_44
Age 35-44
|
AGE45_54
Age 45-54
|
AGE55_64
Age 55-64
|
AGE65_PLUS
Age 65+
|
UNKNOWN
Should never occur but may if Strava API behaviour has changed
|
| Modifier and Type | Method and Description |
|---|---|
static StravaAgeGroup |
create(String id)
Used by JSON deserialisation
|
String |
getDescription() |
String |
getId() |
String |
getValue()
Used by JSON serialisation
|
String |
toString() |
static StravaAgeGroup |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static StravaAgeGroup[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final StravaAgeGroup AGE0_24
public static final StravaAgeGroup AGE25_34
public static final StravaAgeGroup AGE35_44
public static final StravaAgeGroup AGE45_54
public static final StravaAgeGroup AGE55_64
public static final StravaAgeGroup AGE65_PLUS
public static final StravaAgeGroup UNKNOWN
Should never occur but may if Strava API behaviour has changed
public static StravaAgeGroup[] values()
for (StravaAgeGroup c : StravaAgeGroup.values()) System.out.println(c);
public static StravaAgeGroup valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is nullpublic static StravaAgeGroup create(String id)
id - The string representation of the StravaAgeGroup returned by the Strava APIStravaAgeGroup, or UNKNOWN if there is no matchpublic String getDescription()
getDescription in interface StravaReferenceType<String>public String getId()
getId in interface StravaReferenceType<String>public String getValue()
getValue in interface StravaReferenceType<String>StravaAgeGroup to be used in JSONAgeGroupSerializer.serialize(StravaAgeGroup, java.lang.reflect.Type, com.google.gson.JsonSerializationContext)public String toString()
toString in interface StravaReferenceType<String>toString in class Enum<StravaAgeGroup>Enum.toString()Copyright © 2016 Dan Shannon. All rights reserved.