ilog.views.maps.graphic
Class IlvGeodeticPathComputation

java.lang.Object
  extended by ilog.views.maps.graphic.IlvGeodeticPathComputation

public class IlvGeodeticPathComputation
extends Object

IlvGeodeticPathComputation contains methods used to render polygons and polylines while taking into account that the shapes are on the surface of the earth. It is possible to insert the correct interpolated points into each segment, taking into account parameters such as the distance in meters between each intermediary point and the ellipsoid. This class also manages date line wrapping by inserting the necessary interruptions in polygons and polylines that would cause a line to be over half a hemisphere long on the map.

Since:
JViews 7.5

Nested Class Summary
static class IlvGeodeticPathComputation.PointVector
          Stores an array of points that possibly contains null values for interruptions.
 
Field Summary
static double DefaultGeodeticStepSize
          The default distance for intermediary points.
static double DefaultMinDistance
          The default convergence distance for the added points.
static String TEMP_GRAPHIC_PROPERTY_NAME
          A temporary property name used to store a computation in an IlvGraphic instance before a data source copies it.
 
Constructor Summary
IlvGeodeticPathComputation(IlvCoordinateSystem coordinateSystem)
          Creates a polygon computation class to manage geodetic objects and date line wrapping.
 
Method Summary
 IlvPointArray[] computeClosedPath(IlvPointArray[] arrays, boolean orthodromy)
          Creates the correct representation of the raw array of polygons passed as a parameter.
 IlvPointArray[] computeOpenPath(IlvPoint[] points, boolean orthodromy)
          Creates the correct representation of the raw array of polylines passed as a parameter.
 GeneralPath computePath(GeneralPath path, boolean orthodromy)
          Creates the correct representation of the raw path passed as a parameter.
 IlvGeodeticPathComputation.PointVector computePath(IlvPoint pathStart, IlvPoint pathEnd, boolean orthodromy)
          Creates the orthodromy trajectory and adds it to the data.
 double getBearing()
          Returns the bearing.
 double getDistance()
          Returns the distance.
 double getStepDistance()
          Returns the distance for intermediary points.
 void setStepDistance(double stepDistance)
          Sets the distance for intermediary points.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DefaultGeodeticStepSize

public static double DefaultGeodeticStepSize
The default distance for intermediary points.


DefaultMinDistance

public static double DefaultMinDistance
The default convergence distance for the added points.


TEMP_GRAPHIC_PROPERTY_NAME

public static final String TEMP_GRAPHIC_PROPERTY_NAME
A temporary property name used to store a computation in an IlvGraphic instance before a data source copies it. Using this constant is not recommended. It is mainly for ILOG private use.

Since:
JViews 8.1
See Also:
Constant Field Values
Constructor Detail

IlvGeodeticPathComputation

public IlvGeodeticPathComputation(IlvCoordinateSystem coordinateSystem)
Creates a polygon computation class to manage geodetic objects and date line wrapping.

Parameters:
coordinateSystem - The coordinate system.
Method Detail

getStepDistance

public double getStepDistance()
Returns the distance for intermediary points.

Returns:
The distance for intermediary points.

setStepDistance

public void setStepDistance(double stepDistance)
Sets the distance for intermediary points.

Parameters:
stepDistance - The distance for intermediary points.

computePath

public IlvGeodeticPathComputation.PointVector computePath(IlvPoint pathStart,
                                                          IlvPoint pathEnd,
                                                          boolean orthodromy)
Creates the orthodromy trajectory and adds it to the data.

Parameters:
pathStart - The manager coordinate of point 1.
pathEnd - The manager coordinate of point 2.
orthodromy - Set to true so an intermediary point will be added each step distance to transform the straight line into an orthodromy path.
Returns:
The shape created.

computeClosedPath

public IlvPointArray[] computeClosedPath(IlvPointArray[] arrays,
                                         boolean orthodromy)
Creates the correct representation of the raw array of polygons passed as a parameter.

Parameters:
arrays - An array of polygons.
orthodromy - Set to true to compute the orthodromy between each point.
Returns:
A newly created array of PointArray objects.

computeOpenPath

public IlvPointArray[] computeOpenPath(IlvPoint[] points,
                                       boolean orthodromy)
Creates the correct representation of the raw array of polylines passed as a parameter.

Parameters:
points - The array of polylines.
orthodromy - Set to true to compute the orthodromy between each point.
Returns:
A newly created array of PointArray objects.

computePath

public GeneralPath computePath(GeneralPath path,
                               boolean orthodromy)
Creates the correct representation of the raw path passed as a parameter.

Parameters:
path - The path to represent.
orthodromy - Set to true to compute the orthodromy between each point.
Returns:
A newly created polygon or polyline.

getBearing

public double getBearing()
Returns the bearing.

Returns:
The bearing.

getDistance

public double getDistance()
Returns the distance.

Returns:
The distance.


Copyright © 1996-2007 ILOG S.A. All rights reserved.   Documentation homepage.