|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD |
java.lang.Objectjava.lang.Enum<Block>
org.eviline.Block
public enum Block
A block on the playing Field
. There are two block types for each ShapeType
: active and inactive.
Additionally, there is a block type for the outer border around the field. Empty areas in the Field
are stored as nulls.
A block is active if it is a part of the currently active Shape
in the field. Once a Shape
locks
on the field its active blocks become inactive blocks and are stored.
Enum Constant Summary | |
---|---|
G
Ghost |
|
I
|
|
IA
|
|
J
|
|
JA
|
|
L
|
|
LA
|
|
M
iMpossible block |
|
O
|
|
OA
|
|
S
|
|
SA
|
|
T
|
|
TA
|
|
U
Unlikely block |
|
X
Field border |
|
Z
|
|
ZA
|
Method Summary | |
---|---|
Block |
active()
Returns the active version of the current block |
Color |
color()
|
Block |
inactive()
Returns the inactive version of the current block |
boolean |
isActive()
Returns whether this is an active or inactive block |
static Block |
valueOf(String name)
Returns the enum constant of this type with the specified name. |
static Block[] |
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 Block I
public static final Block T
public static final Block S
public static final Block Z
public static final Block O
public static final Block J
public static final Block L
public static final Block IA
public static final Block TA
public static final Block SA
public static final Block ZA
public static final Block OA
public static final Block JA
public static final Block LA
public static final Block X
public static final Block G
public static final Block M
public static final Block U
Method Detail |
---|
public static Block[] values()
for (Block c : Block.values()) System.out.println(c);
public static Block 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 boolean isActive()
public Block active()
public Block inactive()
public Color color()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD |