Oracle Application Server Wireless Java API Reference
B10400-01

oracle.panama.mp
Class PositionArea

java.lang.Object
  |
  +--oracle.panama.mp.PositionArea

public class PositionArea
extends java.lang.Object

PositionArea class. A PositionArea has a center point (longitude, latitude) that represents the mobile target's location. It can optionally have a number representing the accuracy of the positioning. Depending on the provider, it can mean the confidence of the positioning or the probability of the actual position falls in the given area. If the positioner locates a mobile device in a non-point area, you can get a Geometry or Shape object representing the area.

Author:
shan

Constructor Summary
PositionArea(double lon, double lat, double accuracy, oracle.sdoapi.geom.Geometry geom)
          Constructor.
PositionArea(double lon, double lat, double accuracy, oracle.sdoapi.geom.Geometry geom, java.awt.Shape shape, double hUncertainty, double vUncertainty, double altitude, Velocity velocity)
          Constructor.

 

Method Summary
static java.awt.Shape geom2Shape(oracle.sdoapi.geom.Geometry geom)
          Convinience function to convert a Oracle SDO Geometry object to a Shape object.
 double getAccuracy()
          Get the accuracy of the positioning.
 double getAltitude()
          Get the Altitude of the mobile object.
 double getCenterPointLatitude()
          Get the position point latitude.
 double getCenterPointLongitude()
          Get the position point longitude.
 oracle.sdoapi.geom.Geometry getGeometry()
          Get the geometry of the PositionArea.
 double getHUncertainty()
          Get the Horizontal uncertainty of the position.
 java.awt.Shape getShape()
          Get the shape of the PositionArea.
 Velocity getVelocity()
          Get the Velocity of the mobile object.
 double getVUncertainty()
          Get the Vertical uncertainty of the position.
 void setVelocity(Velocity vel)
          Set the Velocity of the mobile object.
 java.lang.String toString()
          toString.

 

Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait

 

Constructor Detail

PositionArea

public PositionArea(double lon,
                    double lat,
                    double accuracy,
                    oracle.sdoapi.geom.Geometry geom)
Constructor. Constructs a PositionArea object.
Parameters:
lon - Longitude of the mobile position.
lat - Latitude of the mobile position.
accuracy - An integer representing the accuracy of the positioning.
geom - An Oracle spatial geometry representing the position area of a mobile device. Use null if a positioning provider does not provide a geometry.

PositionArea

public PositionArea(double lon,
                    double lat,
                    double accuracy,
                    oracle.sdoapi.geom.Geometry geom,
                    java.awt.Shape shape,
                    double hUncertainty,
                    double vUncertainty,
                    double altitude,
Velocity velocity)
Constructor. Constructs a PositionArea object.
Parameters:
lon - Longitude of the mobile position.
lat - Latitude of the mobile position.
accuracy - An integer representing the accuracy of the positioning.
geom - An Oracle spatial geometry representing the position area of a mobile device. Use null if a positioning provider does not provide a geometry.
hUncertainty - Horizontal uncertainty of the position area.
vUncertainty - Vertical uncertainty of the position area.
altitude - Altitude of the position.
velocity - A Velocity object representing the velocity of the the mobile target.
Since:
MP API 2.0
Method Detail

getAccuracy

public double getAccuracy()
Get the accuracy of the positioning. Mobile Positioning framework does not interpret the accuracy. It simply returns the accuracy value that is used to construct a PositionArea. You should refer to the MPProvider information in the PositionResult to decide the exact meaning of this value.
Returns:
A double representing the positioning accuracy. If this information is not available from the provider, then Double.NaN is returned.

getGeometry

public oracle.sdoapi.geom.Geometry getGeometry()
Get the geometry of the PositionArea. If the positioning provider does not provide a geometry, then a null will be returned.
Returns:
An Oracle spatial Geometry.

getCenterPointLongitude

public double getCenterPointLongitude()
Get the position point longitude.
Returns:
A double that represents the longitude of the mobile device position.

getCenterPointLatitude

public double getCenterPointLatitude()
Get the position point latitude.
Returns:
A double that represents the latitude of the mobile device position.

getShape

public java.awt.Shape getShape()
Get the shape of the PositionArea. If the positioning provider does not provide a shape, then a null will be returned.
Returns:
Shape A Shape object.

getHUncertainty

public double getHUncertainty()
Get the Horizontal uncertainty of the position.
Returns:
double A number representing the horizontal uncertainty. If this value is not available from the positioning server then Double.NAN is returned.

getVUncertainty

public double getVUncertainty()
Get the Vertical uncertainty of the position.
Returns:
double A number representing the vertical uncertainty. If this value is not available from the positioning server then Double.NAN is returned.

getVelocity

public Velocity getVelocity()
Get the Velocity of the mobile object.
Returns:
Veloctiy A Velocity object representing the velocity of the mobile object. If velocity is not available from the positioning server then null is returned.

setVelocity

public void setVelocity(Velocity vel)
Set the Velocity of the mobile object.

getAltitude

public double getAltitude()
Get the Altitude of the mobile object.
Returns:
double A double representing the altitude of the mobile object. If altitude is not available from the positioning server then Double.NAN is returned.

toString

public java.lang.String toString()
toString.
Overrides:
toString in class java.lang.Object
Returns:
A string representation of a PositionArea.

geom2Shape

public static java.awt.Shape geom2Shape(oracle.sdoapi.geom.Geometry geom)
Convinience function to convert a Oracle SDO Geometry object to a Shape object. A null will be returned if error occurs in the conversion.
Parameters:
geom - An Oracle SDO Geometry object.
Returns:
Shape A Shape object.

Oracle Application Server Wireless Java API Reference
B10400-01

Copyright © 2003 Oracle Corporation. All Rights Reserved.