Jeospace API

org.jeospace.measure.angle
Class SexagesimalAngleUnit

java.lang.Object
  extended byorg.jeospace.measure.angle.SexagesimalAngleUnit
All Implemented Interfaces:
AngleUnit

public class SexagesimalAngleUnit
extends java.lang.Object
implements AngleUnit

Constant object identifiers of the units of sexigesimal angle representations. The primary (most significant) units of a sexigesimal angle distinguish it's SexagesimalAngleType.

A SexagesimalAngleType.DMS is sub-united into Degrees, Minutes, Seconds (and Microseconds)
A SexagesimalAngleType.HMS is sub-united into Hours, Minutes, Seconds (and Microseconds)

Version:
$Revision: 1.1.1.1 $
Author:
Rex Melton
See Also:
Angle, DecimalAngle, SexagesimalAngle

Field Summary
 double degrees
          The value of a single unit in decimal degrees
static SexagesimalAngleUnit DEGREES
          Constant identifier for units of degrees
static SexagesimalAngleUnit HOURS
          Constant identifier for units of hours
 int index
          The index of the sub-unit within the sexigesimal type
 long micros
          The value of a single unit in microseconds of degree
static SexagesimalAngleUnit MICROSECONDS_OF_DEGREE
          Constant identifier for units of microseconds of degree
static SexagesimalAngleUnit MICROSECONDS_OF_HOUR
          Constant identifier for units of microseconds of hour
static int MINUTE_INDEX
          Minute unit index
static SexagesimalAngleUnit MINUTES_OF_DEGREE
          Constant identifier for units of minutes of degree
static SexagesimalAngleUnit MINUTES_OF_HOUR
          Constant identifier for units of minutes of hour
 java.lang.String name
          The name of the unit of angle
static int PRIMARY_INDEX
          Primary unit index
static int SECOND_INDEX
          Second unit index
static SexagesimalAngleUnit SECONDS_OF_DEGREE
          Constant identifier for units of seconds of degree
static SexagesimalAngleUnit SECONDS_OF_HOUR
          Constant identifier for units of seconds of hour
 java.lang.String symbol
          The symbol of the unit of angle
 SexagesimalAngleType type
          The sexagesimal type of the unit
 
Constructor Summary
protected SexagesimalAngleUnit(java.lang.String name, java.lang.String symbol, SexagesimalAngleType type, int index, double degrees, long micros)
          Construct a SexagesimalAngleUnit object.
 
Method Summary
 double getDegrees()
          Return the double value of the unit in degrees.
 long getMicros()
          Return the long value of the unit in microseconds of degree.
static SexagesimalAngleUnit[] getSexagesimalAngleUnits()
          Return an array of the defined SexagesimalAngleUnit objects
 java.lang.String toString()
          Return a String representation ( the name String ) of this SexagesimalAngleUnit object.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

PRIMARY_INDEX

public static final int PRIMARY_INDEX
Primary unit index

See Also:
Constant Field Values

MINUTE_INDEX

public static final int MINUTE_INDEX
Minute unit index

See Also:
Constant Field Values

SECOND_INDEX

public static final int SECOND_INDEX
Second unit index

See Also:
Constant Field Values

DEGREES

public static final SexagesimalAngleUnit DEGREES
Constant identifier for units of degrees


MINUTES_OF_DEGREE

public static final SexagesimalAngleUnit MINUTES_OF_DEGREE
Constant identifier for units of minutes of degree


SECONDS_OF_DEGREE

public static final SexagesimalAngleUnit SECONDS_OF_DEGREE
Constant identifier for units of seconds of degree


MICROSECONDS_OF_DEGREE

public static final SexagesimalAngleUnit MICROSECONDS_OF_DEGREE
Constant identifier for units of microseconds of degree


HOURS

public static final SexagesimalAngleUnit HOURS
Constant identifier for units of hours


MINUTES_OF_HOUR

public static final SexagesimalAngleUnit MINUTES_OF_HOUR
Constant identifier for units of minutes of hour


SECONDS_OF_HOUR

public static final SexagesimalAngleUnit SECONDS_OF_HOUR
Constant identifier for units of seconds of hour


MICROSECONDS_OF_HOUR

public static final SexagesimalAngleUnit MICROSECONDS_OF_HOUR
Constant identifier for units of microseconds of hour


name

public final java.lang.String name
The name of the unit of angle


symbol

public final java.lang.String symbol
The symbol of the unit of angle


type

public final SexagesimalAngleType type
The sexagesimal type of the unit


index

public final int index
The index of the sub-unit within the sexigesimal type


degrees

public final double degrees
The value of a single unit in decimal degrees


micros

public final long micros
The value of a single unit in microseconds of degree

Constructor Detail

SexagesimalAngleUnit

protected SexagesimalAngleUnit(java.lang.String name,
                               java.lang.String symbol,
                               SexagesimalAngleType type,
                               int index,
                               double degrees,
                               long micros)
Construct a SexagesimalAngleUnit object.

Parameters:
name - the sub-unit of sexigesimal angle
symbol - the unit of angle's symbol
type - the SexagesimalAngleType of which this is a sub-unit
index - the index of the sub-unit within the sexigesimal type
degrees - the double value of a single unit in decimal degrees
micros - the long value of a single unit in microseconds of degree
Method Detail

getDegrees

public double getDegrees()
Return the double value of the unit in degrees.

Specified by:
getDegrees in interface AngleUnit
Returns:
the double value of the unit in degrees.

getMicros

public long getMicros()
Return the long value of the unit in microseconds of degree.

Specified by:
getMicros in interface AngleUnit
Returns:
the long value of the unit in microseconds of degree.

getSexagesimalAngleUnits

public static SexagesimalAngleUnit[] getSexagesimalAngleUnits()
Return an array of the defined SexagesimalAngleUnit objects

Returns:
the array of the defined SexagesimalAngleUnit objects

toString

public java.lang.String toString()
Return a String representation ( the name String ) of this SexagesimalAngleUnit object.

Returns:
a String representation of this SexagesimalAngleUnit object

Jeospace API

Copyright © 2006 - jeospace.org