public enum SnakeDirection extends Enum<SnakeDirection>
| Enum Constant and Description |
|---|
HORIZONTAL_THEN_VERTICAL |
VERTICAL_THEN_HORIZONTAL |
| Modifier and Type | Method and Description |
|---|---|
static SnakeDirection |
getDirection(Point2D pt1,
Point2D pt2) |
static SnakeDirection |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static SnakeDirection[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final SnakeDirection VERTICAL_THEN_HORIZONTAL
public static final SnakeDirection HORIZONTAL_THEN_VERTICAL
public static SnakeDirection[] values()
for (SnakeDirection c : SnakeDirection.values()) System.out.println(c);
public static SnakeDirection 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 static SnakeDirection getDirection(Point2D pt1, Point2D pt2)
Copyright © 2017. All rights reserved.