Package com.anylogic.engine.gis
- java.lang.Object
-
- com.anylogic.engine.gis.AbstractGISRouteProvider
- All Implemented Interfaces:
IGISRouteProvider
,IRouteProvider<Curve<GISMarkupSegment>>
,java.io.Serializable
- Direct Known Subclasses:
AbstractGISRouteProviderWithCache
,PlainGISRouteProvider
@AnyLogicInternalAPI public abstract class AbstractGISRouteProvider extends java.lang.Object implements IGISRouteProvider
- See Also:
- Serialized Form
AbstractGISRouteProvider() |
|
Constructor | Description |
---|
double |
getDistance(double... latLonPoints) |
Calculates distance by route with intermediate points.
|
Curve<GISMarkupSegment> |
getPathData(double... latLonPoints) |
Create route with intermediate points specified by pairs of latitude and longitude.
|
Curve<GISMarkupSegment> |
getPathData(double startLat,
double startLon,
double endLat,
double endLon) |
Creates route from one point to another.
|
int |
getPrecisionInMeters() |
|
boolean |
isThrowError() |
This method is internal and shouldn't be called by user.
it may be removed/renamed in future. |
void |
setPrecisionInMeters(int precisionInMeters) |
|
AbstractGISRouteProvider |
setRouteNotFoundBehavior(GISRouteNotFoundBehavior behavior) |
Configures this route provider to either throw error or
create a straight route if the requested
route can't be found (applicable for route providers
supporting route search).
|
void |
setThrowError(boolean throwError) |
Deprecated.
|
Modifier and Type | Method | Description |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getDistance, getDistance, getDistance, getLength, getPathData, getPathData, getPositionAtOffset, getRoute, getRoute, getRoute, getRoute
public AbstractGISRouteProvider()
public void setPrecisionInMeters(int precisionInMeters)
public int getPrecisionInMeters()
public final Curve<GISMarkupSegment> getPathData(double startLat, double startLon, double endLat, double endLon)
Description copied from interface:
IGISRouteProvider
Creates route from one point to another.
- Specified by:
getPathData
in interfaceIGISRouteProvider
- Parameters:
startLat
- the latitude of the 1st point, measured in degrees (-90 ... (South) ... 0 ... (North) ... +90)startLon
- the longitude of the 1st point, measured in degrees (-180 ... (West) ... 0 ... (East) ... +180)endLat
- the latitude of the 2nd point, measured in degrees (-90 ... (South) ... 0 ... (North) ... +90)endLon
- the longitude of the 2nd point, measured in degrees (-180 ... (West) ... 0 ... (East) ... +180)- Returns:
- the route from one point to another
public final Curve<GISMarkupSegment> getPathData(double... latLonPoints)
Description copied from interface:
IGISRouteProvider
Create route with intermediate points specified by pairs of latitude and longitude.
- Specified by:
getPathData
in interfaceIGISRouteProvider
- Parameters:
latLonPoints
- the array of coordinates ([latitude1, longitude1, latitude2, longitude2, ... latitudeN, longitudeN])- Returns:
- the curve which sequentially connects all specified points
public final double getDistance(double... latLonPoints)
Description copied from interface:
IGISRouteProvider
Calculates distance by route with intermediate points.
- Specified by:
getDistance
in interfaceIGISRouteProvider
- Parameters:
latLonPoints
- the array of coordinates ([latitude1, longitude1, latitude2, longitude2, ... latitudeN, longitudeN])- Returns:
- the distance of route which sequentially connects all specified points
@AnyLogicInternalAPI public boolean isThrowError()
This method is internal and shouldn't be called by user.
it may be removed/renamed in future.
it may be removed/renamed in future.
@Deprecated public void setThrowError(boolean throwError)
Deprecated.
public AbstractGISRouteProvider setRouteNotFoundBehavior(GISRouteNotFoundBehavior behavior)
Configures this route provider to either throw error or
create a straight route if the requested
route can't be found (applicable for route providers
supporting route search).
- Parameters:
behavior
- the behavior- Returns:
- this object, for convenience
-
How can we improve this article?
-