public class PointOfInterestResponse extends Object
| Constructor and Description |
|---|
PointOfInterestResponse(TravelOptions travelOptions,
org.json.JSONObject result,
long requestStart)
Create a response from JSON results, using given travel options
|
| Modifier and Type | Method and Description |
|---|---|
void |
addEdgeWeight(String targetId,
Integer travelTime)
Add travel time to a target
|
Map<String,Integer> |
getEdgeWeights()
Map of source IDs - travel times
|
org.json.JSONObject |
getResult() |
TravelOptions |
getTravelOptions() |
void |
mapResults()
Parse results in JSON to travel times map.
|
public PointOfInterestResponse(TravelOptions travelOptions, org.json.JSONObject result, long requestStart)
travelOptions - travel options, from the requestresult - Travel times in JSONrequestStart - Start time of executionpublic void mapResults()
public void addEdgeWeight(String targetId, Integer travelTime)
targetId - Target IDtravelTime - Travel time for the targetpublic TravelOptions getTravelOptions()
public Map<String,Integer> getEdgeWeights()
public org.json.JSONObject getResult()
Copyright © 2017. All rights reserved.