Enum Class AccountStatus.State

java.lang.Object
java.lang.Enum<AccountStatus.State>
lol.trq.alts.auth.AccountStatus.State
All Implemented Interfaces:
Serializable, Comparable<AccountStatus.State>, Constable
Enclosing class:
AccountStatus

public static enum AccountStatus.State extends Enum<AccountStatus.State>
What an account can be.
Since:
0.8.0
  • Enum Constant Details

    • VALID

      public static final AccountStatus.State VALID
      The stored credentials work as they are.
      Since:
      0.8.0
    • RENEWED

      public static final AccountStatus.State RENEWED
      The credentials were spent and have been renewed; the account carries the new ones.
      Since:
      0.8.0
    • EXPIRED

      public static final AccountStatus.State EXPIRED
      The stored token is not usable, and renewal has not been attempted. The account holds a refresh token, so AltAccountService.refresh(AltAccount) is the next step rather than a fresh interactive login. Only a read-only AltAccountService.check(AltAccount) reports this.
      Since:
      0.8.0
    • REAUTH_REQUIRED

      public static final AccountStatus.State REAUTH_REQUIRED
      The credentials are permanently spent and the account needs a fresh interactive login. Any refresh token held for it has been discarded.
      Since:
      0.8.0
    • NOT_ENTITLED

      public static final AccountStatus.State NOT_ENTITLED
      The credentials authenticated, but the account cannot be played as it stands: it has no Minecraft profile (AltsFailure.Kind.NOT_ENTITLED), or Xbox Live refused to authorize it (AltsFailure.Kind.XBOX_DENIED). Neither retrying nor re-authenticating helps.
      Since:
      0.8.0
    • UNREACHABLE

      public static final AccountStatus.State UNREACHABLE
      The service could not be reached, failed (AltsFailure.Kind.NETWORK), or is throttling the caller (AltsFailure.Kind.RATE_LIMITED). Nothing was spent. An outage is worth a retry; a rate limit is worth a wait, and the failure's kind says which.
      Since:
      0.8.0
    • UNKNOWN

      public static final AccountStatus.State UNKNOWN
      Something else went wrong, which the library could not classify.
      Since:
      0.8.0
  • Method Details

    • values

      public static AccountStatus.State[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static AccountStatus.State valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null