|
deegree 2.1 (2007/11/08 09:57 build-328-official) | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.media.jai.EnumeratedParameter
org.deegree.model.csct.cs.AxisOrientation
public final class AxisOrientation
Orientation of axis. Some coordinate systems use non-standard orientations. For example, the
first axis in South African grids usually points West, instead of East. This information is
obviously relevant for algorithms converting South African grid coordinates into Lat/Long.
The natural ordering for axis orientations is defined as (EAST-WEST), (NORTH-SOUTH),
(UP-DOWN), (FUTURE-PAST) and OTHER, which is the ordering for a (x,y,z,t)
coordinate system. This means that when an array of AxisOrientation
s is sorted
using Arrays.sort(Object[])
, EAST and WEST orientations will appears first.
NORTH and SOUTH will be next, followed by UP and DOWN, etc.
Care should be exercised if AxisOrientation
s are to be used as keys in a sorted
map or elements in a sorted set, as AxisOrientation
's natural ordering is
inconsistent with equals. See Comparable
, SortedMap
or
SortedSet
for more information.
Field Summary | |
---|---|
static int |
CS_AO_Down
Increasing ordinates values go down. |
static int |
CS_AO_East
Increasing ordinates values go East. |
static int |
CS_AO_North
Increasing ordinates values go North. |
static int |
CS_AO_Other
Unknown or unspecified axis orientation. |
static int |
CS_AO_South
Increasing ordinates values go South. |
static int |
CS_AO_Up
Increasing ordinates values go up. |
static int |
CS_AO_West
Increasing ordinates values go West. |
static AxisOrientation |
DOWN
Increasing ordinates values go down. |
static AxisOrientation |
EAST
Increasing ordinates values go East. |
static AxisOrientation |
FUTURE
Increasing time go toward future. |
static AxisOrientation |
NORTH
Increasing ordinates values go North. |
static AxisOrientation |
OTHER
Unknown or unspecified axis orientation. |
static AxisOrientation |
PAST
Increasing time go toward past. |
static AxisOrientation |
SOUTH
Increasing ordinates values go South. |
static AxisOrientation |
UP
Increasing ordinates values go up. |
static AxisOrientation |
WEST
Increasing ordinates values go West. |
Method Summary | |
---|---|
AxisOrientation |
absolute()
Returns the "absolute" orientation of this axis. |
int |
compareTo(Object ao)
Compares this AxisOrientation with the specified orientation. |
static AxisOrientation |
getEnum(int value)
Return the enum for the specified value. |
String |
getName(Locale locale)
Returns this enum's name in the specified locale. |
AxisOrientation |
inverse()
Returns the opposite orientation of this axis. |
Methods inherited from class javax.media.jai.EnumeratedParameter |
---|
equals, getName, getValue, hashCode, toString |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final int CS_AO_Other
public static final int CS_AO_North
public static final int CS_AO_South
public static final int CS_AO_East
public static final int CS_AO_West
public static final int CS_AO_Up
public static final int CS_AO_Down
public static final AxisOrientation OTHER
public static final AxisOrientation NORTH
public static final AxisOrientation SOUTH
public static final AxisOrientation EAST
public static final AxisOrientation WEST
public static final AxisOrientation UP
public static final AxisOrientation DOWN
public static final AxisOrientation FUTURE
public static final AxisOrientation PAST
Method Detail |
---|
public static AxisOrientation getEnum(int value) throws NoSuchElementException
value
- The enum value.
NoSuchElementException
- if there is no enum for the specified value.public String getName(Locale locale)
locale
- The locale, or null
for the default locale.
public AxisOrientation inverse()
public AxisOrientation absolute()
Math.abs(int)
method in that "negative" orientation (SOUTH
,
WEST
, DOWN
, PAST
) are changed for their
positive counterpart (NORTH
, EAST
, UP
,
FUTURE
). More specifically, the following conversion table is applied. Orientation | Absolute value |
---|---|
NORTH | NORTH |
SOUTH | NORTH |
EAST | EAST |
WEST | EAST |
UP | UP |
DOWN | UP |
FUTURE | FUTURE |
PAST | FUTURE |
OTHER | OTHER |
public int compareTo(Object ao)
AxisOrientation
with the specified orientation. The
natural ordering is defined as (EAST-WEST), (NORTH-SOUTH), (UP-DOWN),
(FUTURE-PAST) and OTHER, which is the ordering for a (x,y,z,t)
coordinate system. Two AxisOrientation
that are among the same axis but with
an opposite direction (e.g. EAST vs WEST) are considered equal by this method.
compareTo
in interface Comparable
ao
- An AxisOrientation
object to be compared with.
ClassCastException
- if ao
is not an AxisOrientation
object.
|
deegree 2.1 (2007/11/08 09:57 build-328-official) | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
an open source project founded by lat/lon, Bonn, Germany.
For more information visit: http://deegree.sourceforge.net