|
Copyright 2008 - 2009 Tony Morris, Runar Bjarnason, Tom Adams, Brad Clow, Ricky Clarkson, Nick Partridge, Jason Zaugg This software is released under an open source BSD licence. |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD |
java.lang.Objectjava.lang.Enum<Digit>
fj.Digit
public enum Digit
The digits zero to nine.
Enum Constant Summary | |
---|---|
_0
Zero. |
|
_1
One. |
|
_2
Two. |
|
_3
Three. |
|
_4
Four. |
|
_5
Five. |
|
_6
Six. |
|
_7
Seven. |
|
_8
Eight. |
|
_9
Nine. |
Field Summary | |
---|---|
static F<Character,Option<Digit>> |
fromChar
First-class conversion from a character to a digit. |
static F<Long,Digit> |
fromLong
First-class conversion from a long to a digit. |
static F<Digit,Character> |
toChar
First-class conversion from a digit to a character. |
static F<Digit,Long> |
toLong
First-class conversion from digit to a long. |
Method Summary | |
---|---|
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(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. |
Methods inherited from class java.lang.Enum |
---|
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Enum Constant Detail |
---|
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
Field Detail |
---|
public static final F<Digit,Long> toLong
public static final F<Long,Digit> fromLong
public static final F<Digit,Character> toChar
public static final F<Character,Option<Digit>> fromChar
Method Detail |
---|
public static Digit[] values()
for (Digit c : Digit.values()) System.out.println(c);
public static Digit valueOf(String name)
name
- the name of the enum constant to be returned.
IllegalArgumentException
- if this enum type has no constant
with the specified name
NullPointerException
- if the argument is nullpublic long toLong()
public char toChar()
public static Digit fromLong(long i)
i
- The long to convert.
public static Option<Digit> fromChar(char c)
c
- The character to convert.
|
Copyright 2008 - 2009 Tony Morris, Runar Bjarnason, Tom Adams, Brad Clow, Ricky Clarkson, Nick Partridge, Jason Zaugg This software is released under an open source BSD licence. |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD |