oracle.panama.spatial.router
Class RoutingResult
java.lang.Object
|
+--oracle.panama.spatial.router.RoutingResult
- public class RoutingResult
- extends java.lang.Object
This class defines the result of a routing service. Such a result contains
a list of single maneuvers that are part of the complete route.
This class defines immutable objects and is thread-safe.
RoutingResult(double time,
int timeUnit,
double distance,
int distUnit,
Point[] geometry,
Maneuver[] maneuvers,
java.awt.Image[] overviewMaps,
java.net.URL[] overviewMapURLs)
Constructor |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
MILES
public static final int MILES
KILOMETERS
public static final int KILOMETERS
SECOND
public static final int SECOND
MINUTE
public static final int MINUTE
HOUR
public static final int HOUR
METERS
public static final int METERS
RoutingResult
public RoutingResult(double time,
int timeUnit,
double distance,
int distUnit,
Point[] geometry,
Maneuver[] maneuvers,
java.awt.Image[] overviewMaps,
java.net.URL[] overviewMapURLs)
- Constructor
getRoutingProvider
public ProviderCredit getRoutingProvider()
setRoutingProvider
public void setRoutingProvider(ProviderCredit credit)
getTime
public double getTime()
- Get the total driving time.
getDistance
public double getDistance()
- Get the total driving distance.
getTimeUnit
public int getTimeUnit()
- Get the time unit. Currently supported time units are:
SECOND -- second
MINUTE -- minute
HOUR -- hour
getTimeUnitString
public java.lang.String getTimeUnitString()
- Get the time unit in string format.
getDistanceUnit
public int getDistanceUnit()
- Get the distance unit. Currently supported distance units are:
KILOMETERS -- Kilometer
MILES -- Miles
getDistanceUnitString
public java.lang.String getDistanceUnitString()
- Get the distance unit in string format.
getManeuvers
public Maneuver[] getManeuvers()
- Get the Maneuver array of the result.
getOverviewMapURL
public java.net.URL[] getOverviewMapURL()
- Get the URL of overview maps. Note that a route can have multiple overview
maps because of possible via points.
getOverviewMap
public java.awt.Image[] getOverviewMap()
- Get the overview maps in Java Image. This is currently not supported.
getOverviewGeometry
public Point[] getOverviewGeometry()
- Get the geometry, i.e., shape points along the route.
toString
public java.lang.String toString()
- Overrides:
toString
in class java.lang.Object
toString
public java.lang.String toString(boolean reqMapURL,
boolean reqGeometry)