|
The Physiologist's Friend Simulation API | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectch.unizh.ini.friend.topology.HexDirection
public class HexDirection
Represents a topological direction in the hexagonal arrangement of cells in the retina. A direction is represented in the hex arrangement as shown in this image:
Field Summary | |
---|---|
protected int |
dir
|
static int |
E
a hex direction |
static int |
NE
a hex direction |
static int |
NW
a hex direction |
static int |
SE
a hex direction |
static int |
SW
a hex direction |
static int |
W
a hex direction |
Constructor Summary | |
---|---|
HexDirection()
Creates a new instance of Direction with direction set to -1. |
|
HexDirection(int i)
Creates new instance with given direction. |
Method Summary | |
---|---|
int |
get()
gets the direction as a int, 0-5 CCW from east, non negative. |
double |
getAngle()
get angle in radians. |
static void |
main(String[] args)
tests HexDirection |
void |
set(int i)
sets the direction |
String |
toString()
returns int direction, 0-5 CCW from east and non negative |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected int dir
public static final int E
public static final int NE
public static final int NW
public static final int W
public static final int SW
public static final int SE
Constructor Detail |
---|
public HexDirection()
public HexDirection(int i)
Method Detail |
---|
public int get()
public void set(int i)
public double getAngle()
public static void main(String[] args)
public String toString()
toString
in class Object
|
http://www.ini.unizh.ch/~tobi/friend | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |