/** * Matrix API * The Matrix API is part of the GraphHopper Directions API and with this API you can calculate many-to-many distances, times or routes a lot more efficient than calling the Routing API multiple times. In the Routing API we support multiple points, so called 'via points', which results in one route being calculated. The Matrix API results in NxM routes or more precise NxM weights, distances or times being calculated but is a lot faster compared to NxM single requests. The most simple example is a tourist trying to decide which pizza is close to him instead of using beeline distance she can calculate a 1x4 matrix. Or a delivery service in the need of often big NxN matrices to solve vehicle routing problems. E.g. the GraphHopper Route Optimization API uses the Matrix API under the hood to achieve this. * @param key Get your key at graphhopper.com (required) * @param point Specifiy multiple points for which the weight-, route-, time- or distance-matrix should be calculated. In this case the starts are identical to the destinations. If there are N points, then NxN entries will be calculated. The order of the point parameter is important. Specify at least three points. Cannot be used together with from_point or to_point. Is a string with the format latitude,longitude. (optional) * @param fromPoint The starting points for the routes. E.g. if you want to calculate the three routes A-&gt;1, A-&gt;2, A-&gt;3 then you have one from_point parameter and three to_point parameters. Is a string with the format latitude,longitude. (optional) * @param toPoint The destination points for the routes. Is a string with the format latitude,longitude. (optional) * @param outArray Specifies which arrays should be included in the response. Specify one or more of the following options 'weights', 'times', 'distances'. To specify more than one array use e.g. out_array=times&out_array=distances. The units of the entries of distances are meters, of times are seconds and of weights is arbitrary and it can differ for different vehicles or versions of this API. (optional) * @param vehicle The vehicle for which the route should be calculated. Other vehicles are foot, bike, mtb, racingbike, motorcycle, small_truck, bus and truck. See here for the details. (optional, default to car) * @return ApiResponse<MatrixResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ public ApiResponse<MatrixResponse> matrixGetWithHttpInfo(String key, List<String> point, String fromPoint, String toPoint, List<String> outArray, String vehicle) throws ApiException { com.squareup.okhttp.Call call = matrixGetValidateBeforeCall(key, point, fromPoint, toPoint, outArray, vehicle, null, null); Type localVarReturnType = new TypeToken<MatrixResponse>(){}.getType(); return apiClient.execute(call, localVarReturnType); }
/** * Matrix API * The Matrix API is part of the GraphHopper Directions API and with this API you can calculate many-to-many distances, times or routes a lot more efficient than calling the Routing API multiple times. In the Routing API we support multiple points, so called 'via points', which results in one route being calculated. The Matrix API results in NxM routes or more precise NxM weights, distances or times being calculated but is a lot faster compared to NxM single requests. The most simple example is a tourist trying to decide which pizza is close to him instead of using beeline distance she can calculate a 1x4 matrix. Or a delivery service in the need of often big NxN matrices to solve vehicle routing problems. E.g. the GraphHopper Route Optimization API uses the Matrix API under the hood to achieve this. * @param key Get your key at graphhopper.com (required) * @param point Specifiy multiple points for which the weight-, route-, time- or distance-matrix should be calculated. In this case the starts are identical to the destinations. If there are N points, then NxN entries will be calculated. The order of the point parameter is important. Specify at least three points. Cannot be used together with from_point or to_point. Is a string with the format latitude,longitude. (optional) * @param fromPoint The starting points for the routes. E.g. if you want to calculate the three routes A-&gt;1, A-&gt;2, A-&gt;3 then you have one from_point parameter and three to_point parameters. Is a string with the format latitude,longitude. (optional) * @param toPoint The destination points for the routes. Is a string with the format latitude,longitude. (optional) * @param outArray Specifies which arrays should be included in the response. Specify one or more of the following options 'weights', 'times', 'distances'. To specify more than one array use e.g. out_array=times&out_array=distances. The units of the entries of distances are meters, of times are seconds and of weights is arbitrary and it can differ for different vehicles or versions of this API. (optional) * @param vehicle The vehicle for which the route should be calculated. Other vehicles are foot, bike, mtb, racingbike, motorcycle, small_truck, bus and truck. See here for the details. (optional, default to car) * @return ApiResponse<MatrixResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ public ApiResponse<MatrixResponse> matrixGetWithHttpInfo(String key, List<String> point, String fromPoint, String toPoint, List<String> outArray, String vehicle) throws ApiException { com.squareup.okhttp.Call call = matrixGetValidateBeforeCall(key, point, fromPoint, toPoint, outArray, vehicle, null, null); Type localVarReturnType = new TypeToken<MatrixResponse>(){}.getType(); return apiClient.execute(call, localVarReturnType); }
/** * Matrix API * The Matrix API is part of the GraphHopper Directions API and with this API you can calculate many-to-many distances, times or routes a lot more efficient than calling the Routing API multiple times. In the Routing API we support multiple points, so called 'via points', which results in one route being calculated. The Matrix API results in NxM routes or more precise NxM weights, distances or times being calculated but is a lot faster compared to NxM single requests. The most simple example is a tourist trying to decide which pizza is close to him instead of using beeline distance she can calculate a 1x4 matrix. Or a delivery service in the need of often big NxN matrices to solve vehicle routing problems. E.g. the GraphHopper Route Optimization API uses the Matrix API under the hood to achieve this. * @param key Get your key at graphhopper.com (required) * @param point Specifiy multiple points for which the weight-, route-, time- or distance-matrix should be calculated. In this case the starts are identical to the destinations. If there are N points, then NxN entries will be calculated. The order of the point parameter is important. Specify at least three points. Cannot be used together with from_point or to_point. Is a string with the format latitude,longitude. (optional) * @param fromPoint The starting points for the routes. E.g. if you want to calculate the three routes A-&gt;1, A-&gt;2, A-&gt;3 then you have one from_point parameter and three to_point parameters. Is a string with the format latitude,longitude. (optional) * @param toPoint The destination points for the routes. Is a string with the format latitude,longitude. (optional) * @param pointHint Optional parameter. Specifies a hint for each `point` parameter to prefer a certain street for the closest location lookup. E.g. if there is an address or house with two or more neighboring streets you can control for which street the closest location is looked up. (optional) * @param fromPointHint For the from_point parameter. See point_hint (optional) * @param toPointHint For the to_point parameter. See point_hint (optional) * @param outArray Specifies which arrays should be included in the response. Specify one or more of the following options 'weights', 'times', 'distances'. To specify more than one array use e.g. out_array=times&out_array=distances. The units of the entries of distances are meters, of times are seconds and of weights is arbitrary and it can differ for different vehicles or versions of this API. (optional) * @param vehicle The vehicle for which the route should be calculated. Other vehicles are foot, small_truck etc (optional, default to car) * @return ApiResponse<MatrixResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ public ApiResponse<MatrixResponse> matrixGetWithHttpInfo(String key, List<String> point, List<String> fromPoint, List<String> toPoint, List<String> pointHint, List<String> fromPointHint, List<String> toPointHint, List<String> outArray, String vehicle) throws ApiException { com.squareup.okhttp.Call call = matrixGetValidateBeforeCall(key, point, fromPoint, toPoint, pointHint, fromPointHint, toPointHint, outArray, vehicle, null, null); Type localVarReturnType = new TypeToken<MatrixResponse>(){}.getType(); return apiClient.execute(call, localVarReturnType); }
com.squareup.okhttp.Call call = matrixGetValidateBeforeCall(key, point, fromPoint, toPoint, outArray, vehicle, progressListener, progressRequestListener); Type localVarReturnType = new TypeToken<MatrixResponse>(){}.getType(); apiClient.executeAsync(call, localVarReturnType, callback);
com.squareup.okhttp.Call call = matrixGetValidateBeforeCall(key, point, fromPoint, toPoint, outArray, vehicle, progressListener, progressRequestListener); Type localVarReturnType = new TypeToken<MatrixResponse>(){}.getType(); apiClient.executeAsync(call, localVarReturnType, callback);
com.squareup.okhttp.Call call = matrixGetValidateBeforeCall(key, point, fromPoint, toPoint, pointHint, fromPointHint, toPointHint, outArray, vehicle, progressListener, progressRequestListener); Type localVarReturnType = new TypeToken<MatrixResponse>(){}.getType(); apiClient.executeAsync(call, localVarReturnType, callback);