Enum Constant and Description |
---|
_0
Zero.
|
_1
One.
|
_2
Two.
|
_3
Three.
|
_4
Four.
|
_5
Five.
|
_6
Six.
|
_7
Seven.
|
_8
Eight.
|
_9
Nine.
|
Modifier and Type | Field and Description |
---|---|
static F<java.lang.Character,Option<Digit>> |
fromChar
First-class conversion from a character to a digit.
|
static F<java.lang.Long,Digit> |
fromLong
First-class conversion from a long to a digit.
|
static F<Digit,java.lang.Character> |
toChar
First-class conversion from a digit to a character.
|
static F<Digit,java.lang.Long> |
toLong
First-class conversion from digit to a long.
|
Modifier and Type | Method and Description |
---|---|
static Option<Digit> |
fromChar(char c)
Converts the given character in the given long value to a digit.
|
static Digit |
fromLong(long i)
Converts the right-most digit in the given long value to a digit.
|
char |
toChar()
Converts this digit to a character.
|
long |
toLong()
Converts this digit to a long.
|
static Digit |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static Digit[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final Digit _0
public static final Digit _1
public static final Digit _2
public static final Digit _3
public static final Digit _4
public static final Digit _5
public static final Digit _6
public static final Digit _7
public static final Digit _8
public static final Digit _9
public static final F<Digit,java.lang.Long> toLong
public static final F<java.lang.Long,Digit> fromLong
public static final F<Digit,java.lang.Character> toChar
public static Digit[] values()
for (Digit c : Digit.values()) System.out.println(c);
public static Digit valueOf(java.lang.String name)
name
- the name of the enum constant to be returned.java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is nullpublic long toLong()
public char toChar()
public static Digit fromLong(long i)
i
- The long to convert.