-
- All Implemented Interfaces:
-
android.os.Parcelable
public interface Route implements Parcelable
Interface that exposes the route proprieties.
A whole route is from the origin to the destination. If there are stop points between the origin/destination, the route is split into route legs. If there are no stop points, the route will contain only one route leg.
Route proprieties are the following:
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public class
Route.RouteBuilder
a helper class using for rebuild route from input serialized data.
-
Method Summary
Modifier and Type Method Description abstract String
getID()
Gets the unique id of current route. abstract List<RouteLeg>
getRouteLegList()
Gets the route legs int the current route. abstract List<TravelPoint>
getTravelPoints()
Get all travel locations along the route, including origin and final destination. abstract int
getTrafficLightCount()
Gets the traffic light count along the route. abstract float
getDuration()
Gets the ETT cost for the route in seconds. abstract int
getDistance()
Gets the route distance in meters. abstract int
getTrafficDelay()
Gets the traffic delay in current route in seconds. abstract int
getRouteStyle()
Gets the route style of the generated route. abstract int
getContentLevel()
Gets the calculation content level of the generated route. abstract boolean
isCloudRoute()
Check if the current route is calculated by the cloud or not. abstract Array<byte>
serialization()
Serialize the Route object to byte array. abstract void
dispose()
Releases all resources used by the current Route object. -
-
Method Detail
-
getID
abstract String getID()
Gets the unique id of current route. It represents a route from functionality perspective, not memory object perspective, by calculating based on route geometry, guidance information, calculation time, and etc. When current route is serialized and deserialized, this id will not change.
-
getRouteLegList
abstract List<RouteLeg> getRouteLegList()
Gets the route legs int the current route. If the route doesn't have stop points the route leg list will have only one element that will represent the whole route. If there are stop points (or waypoints) the route will be split between start point, way-points and destination, each route section representing a route leg.
-
getTravelPoints
abstract List<TravelPoint> getTravelPoints()
Get all travel locations along the route, including origin and final destination. The sequence of travel points is aligned with driving direction, starting from origin, through waypoints if available and ending at final destination. There are 2 travel points at least for a route, the 2nd travel point is matched with the end point of 1st leg, 3nd one is matched with end point of 2nd leg and so forth.
-
getTrafficLightCount
abstract int getTrafficLightCount()
Gets the traffic light count along the route.
-
getDuration
abstract float getDuration()
Gets the ETT cost for the route in seconds.
-
getDistance
abstract int getDistance()
Gets the route distance in meters.
-
getTrafficDelay
abstract int getTrafficDelay()
Gets the traffic delay in current route in seconds. To detect the congestion with different visualization.
-
getRouteStyle
abstract int getRouteStyle()
Gets the route style of the generated route. Can be any value from RouteStyle interface.
-
getContentLevel
abstract int getContentLevel()
Gets the calculation content level of the generated route. Can be any value from ContentLevel interface.
-
isCloudRoute
abstract boolean isCloudRoute()
Check if the current route is calculated by the cloud or not.
-
serialization
abstract Array<byte> serialization()
Serialize the Route object to byte array.
-
dispose
abstract void dispose()
Releases all resources used by the current Route object.
-
-
-
-