public class DirectionsResponse
extends java.lang.Object
| Constructor and Description |
|---|
DirectionsResponse()
Empty constructor
|
DirectionsResponse(java.util.List<DirectionsRoute> routes,
java.util.List<DirectionsWaypoint> waypoints)
Constructor taking in both a list of
DirectionsRoute and a list of DirectionsWaypoints. |
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getCode()
String indicating the state of the response.
|
java.util.List<DirectionsRoute> |
getRoutes()
List containing all the different route options.
|
java.util.List<DirectionsWaypoint> |
getWaypoints()
List with Waypoints of locations snapped to the road and path network and appear in the List
in the order of the input coordinates.
|
void |
setCode(java.lang.String code)
String indicating the state of the response.
|
void |
setRoutes(java.util.List<DirectionsRoute> routes)
List containing all the different route options.
|
void |
setWaypoints(java.util.List<DirectionsWaypoint> waypoints)
List with Waypoints of locations snapped to the road and path network and should appear in the List
in the order of the input coordinates.
|
public DirectionsResponse()
public DirectionsResponse(java.util.List<DirectionsRoute> routes, java.util.List<DirectionsWaypoint> waypoints)
DirectionsRoute and a list of DirectionsWaypoints.routes - list of routes you can pass in while building this object.waypoints - list of waypoints you can pass in while building this object. Ideally these should match what was
used to crate the route.public java.lang.String getCode()
public void setCode(java.lang.String code)
code - "Ok", "NoRoute", "ProfileNotFound", or "InvalidInput".public java.util.List<DirectionsWaypoint> getWaypoints()
DirectionsWaypoint objects.public void setWaypoints(java.util.List<DirectionsWaypoint> waypoints)
waypoints - List of DirectionsWaypoint objects.public java.util.List<DirectionsRoute> getRoutes()
DirectionsRoute objects.public void setRoutes(java.util.List<DirectionsRoute> routes)
routes - List of DirectionsRoute objects.