public class Cube.Face extends Object implements IFace
Modifier and Type | Field and Description |
---|---|
private Colors[][] |
colors |
(package private) Orientation |
dynamicOrientation |
(package private) Orientation |
orientation |
Constructor and Description |
---|
Cube.Face(Orientation orientation)
Constructor of an object of the type face.
|
Modifier and Type | Method and Description |
---|---|
Colors |
getColor(int row,
int col)
Returns the color of a position in a face
|
(package private) void |
setColor(int row,
int col,
Colors color)
Sets a color to a position in a face
|
void |
turn(Direction direction)
Represents a turn of the face in a desired direction.
|
final Orientation orientation
private Colors[][] colors
Orientation dynamicOrientation
public Cube.Face(Orientation orientation)
orientation
- The initial orientation of the facepublic Colors getColor(int row, int col)
void setColor(int row, int col, Colors color)
row
- Row in a facecol
- Column in a facepublic void turn(Direction direction)