Package com.treescrub.spedran.data
Class User
- java.lang.Object
-
- com.treescrub.spedran.data.Resource
-
- com.treescrub.spedran.data.IdentifiableResource
-
- com.treescrub.spedran.data.User
-
public class User extends IdentifiableResource
Represents a user on SRC.
This class is immutable and thread-safe.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description UserAssetsgetAssets()Gets theUserAssetsfor this user.GamesRequestgetGamesModerated()Gets a newGamesRequestbuilder object to request all the games this user moderates.Optional<Link>getHitboxLink()Gets the link to this user's Hitbox account.Optional<UserLocation>getLocation()Gets the location that this user specified.NamesgetNames()Gets theNamesfor this user.NameStylegetNameStyle()Gets theNameStylefor this user.UserPBsRequestgetPersonalBests()Gets a newUserPBsRequestbuilder object to request this user's personal best runs.Optional<String>getPronouns()Gets the user specified pronouns for this user.UserRolegetRole()Gets the role of this user across the entire site.RunsRequestgetRuns()Gets a newRunsRequestbuilder object to request all of this user's runs.Optional<Instant>getSignupTime()Gets the time that this user signed up on SRC.Optional<Link>getSpeedrunsLiveLink()Gets the link to this user's SpeedRunsLive account.Optional<Link>getTwitchLink()Gets the link to this user's Twitch account.Optional<Link>getTwitterLink()Gets the link to this user's Twitter account.StringgetWeblink()Gets the link to this user on SRC.Optional<Link>getYoutubeLink()Gets the link to this user's YouTube channel.booleanhasSupporterAnimation()Gets whether this user has the name color supporter animation enabled.StringtoString()-
Methods inherited from class com.treescrub.spedran.data.IdentifiableResource
equals, getId, hashCode
-
-
-
-
Method Detail
-
getRuns
public RunsRequest getRuns()
Gets a newRunsRequestbuilder object to request all of this user's runs.- Returns:
- a
RunsRequestbuilder
-
getGamesModerated
public GamesRequest getGamesModerated()
Gets a newGamesRequestbuilder object to request all the games this user moderates.- Returns:
- a
GamesRequestbuilder
-
getPersonalBests
public UserPBsRequest getPersonalBests()
Gets a newUserPBsRequestbuilder object to request this user's personal best runs.- Returns:
- a
UserPBsRequestbuilder
-
getNames
public Names getNames()
Gets theNamesfor this user.- Returns:
- a
Nameswith this user's names
-
hasSupporterAnimation
public boolean hasSupporterAnimation()
Gets whether this user has the name color supporter animation enabled.- Returns:
- whether this user has the supporter animation
-
getPronouns
public Optional<String> getPronouns()
Gets the user specified pronouns for this user.- Returns:
- an
Optionalcontaining this user's pronouns
-
getWeblink
public String getWeblink()
Gets the link to this user on SRC.- Returns:
- a link to this user's profile
-
getNameStyle
public NameStyle getNameStyle()
Gets theNameStylefor this user.- Returns:
- a
NameStyleof this user
-
getRole
public UserRole getRole()
Gets the role of this user across the entire site.- Returns:
- the
UserRoleof this user on SRC itself
-
getSignupTime
public Optional<Instant> getSignupTime()
Gets the time that this user signed up on SRC.- Returns:
- an
Instant
-
getLocation
public Optional<UserLocation> getLocation()
Gets the location that this user specified.- Returns:
- an
Optionalwith aUserLocationwith this user's location in the world
-
getHitboxLink
public Optional<Link> getHitboxLink()
Gets the link to this user's Hitbox account.
Hitbox.tv is shut down, so the returned link will not be a valid page.
-
getSpeedrunsLiveLink
public Optional<Link> getSpeedrunsLiveLink()
Gets the link to this user's SpeedRunsLive account.
-
getAssets
public UserAssets getAssets()
Gets theUserAssetsfor this user.- Returns:
- a
UserAssetsobject
-
-