org.geotools.geometry.jts.spatialschema.geometry.primitive
Class BearingImpl

java.lang.Object
  extended by org.geotools.geometry.jts.spatialschema.geometry.primitive.BearingImpl
All Implemented Interfaces:
org.opengis.geometry.primitive.Bearing

public class BearingImpl
extends java.lang.Object
implements org.opengis.geometry.primitive.Bearing

Represents direction in the coordinate reference system. In a 2D coordinate reference system, this can be accomplished using a "angle measured from true north" or a 2D vector point in that direction. In a 3D coordinate reference system, two angles or any 3D vector is possible. If both a set of angles and a vector are given, then they shall be consistent with one another.

Version:
2.0
Author:
ISO/DIS 19107, OpenGIS® consortium

Constructor Summary
BearingImpl(double[] angles, double[] direction)
           
 
Method Summary
 double[] getAngles()
          Returns the azimuth and (optionnaly) the altitude.
 double[] getDirection()
          Returns the direction as a vector.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BearingImpl

public BearingImpl(double[] angles,
                   double[] direction)
Method Detail

getAngles

public double[] getAngles()
Returns the azimuth and (optionnaly) the altitude. In this variant of bearing usually used for 2D coordinate systems, the first angle (azimuth) is measured from the first coordinate axis (usually north) in a counterclockwise fashion parallel to the reference surface tangent plane. If two angles are given, the second angle (altitude) usually represents the angle above (for positive angles) or below (for negative angles) a local plane parallel to the tangent plane of the reference surface.

Specified by:
getAngles in interface org.opengis.geometry.primitive.Bearing
Returns:
An array of length 0, 1 or 2 containing the azimuth and altitude angles.

getDirection

public double[] getDirection()
Returns the direction as a vector. In this variant of bearing usually used for 3D coordinate systems, the direction is express as an arbitrary vector, in the coordinate system.

Specified by:
getDirection in interface org.opengis.geometry.primitive.Bearing
Returns:
The direction.


Copyright © 1996-2010 Geotools. All Rights Reserved.