public enum UserCodeCharset extends Enum<UserCodeCharset>
user_code)
in Device Flow.
See "6.1. User Code Recommendations" in OAuth 2.0 Device Authorization Grant for recommendations for user code values.
| Enum Constant and Description |
|---|
BASE20
"BCDFGHJKLMNPQRSTVWXZ", 20 upper-case non-vowel characters.
|
NUMERIC
"0123456789", 10 digit characters from '0' to '9'.
|
| Modifier and Type | Method and Description |
|---|---|
static UserCodeCharset |
getByValue(short value)
Find an instance of this enum by a value.
|
String |
getCharacters()
Get the characters in this characters set.
|
short |
getValue()
Get the integer representation of this enum instance.
|
static UserCodeCharset[] |
toArray(int bits) |
static int |
toBits(EnumSet<UserCodeCharset> set) |
static EnumSet<UserCodeCharset> |
toSet(int bits) |
static EnumSet<UserCodeCharset> |
toSet(UserCodeCharset[] array) |
static UserCodeCharset |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static UserCodeCharset[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final UserCodeCharset BASE20
public static final UserCodeCharset NUMERIC
public static UserCodeCharset[] values()
for (UserCodeCharset c : UserCodeCharset.values()) System.out.println(c);
public static UserCodeCharset 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 short getValue()
public static UserCodeCharset getByValue(short value)
value - The integer representation of the instance to find.null if not found.public String getCharacters()
public static int toBits(EnumSet<UserCodeCharset> set)
public static UserCodeCharset[] toArray(int bits)
public static EnumSet<UserCodeCharset> toSet(int bits)
public static EnumSet<UserCodeCharset> toSet(UserCodeCharset[] array)
Copyright © 2019. All rights reserved.