Contents
How to create a surface in OpenTripPlanner API?
See org.opentripplanner.api.resource.SurfaceResource, functions createSurface and tileGet The basic idea is to create a surface for a “batch” or one-to-many OTP search, then using the returned ID fetch the tiles from a URL under that surface ID. A Jersey web service resource class that returns a grid with time for a set of points.
How to render isochrone geometry in OpenTripPlanner?
Tile rendering goes through TileRendererManager which select the appropriate renderer for the given layer. Return isochrone geometry as a set of GeoJSON or zipped-shapefile multi-polygons.
How are get and setter used in OpenTripPlanner?
The GET methods both use makeContours which in turn uses makePoints (where range checking occurs). Putting “@Setter” on all the parameters would allow resource classes to be used outside Jersey. Surfaces cannot be isolated per-router because sometimes you want to compare two surfaces from different router IDs.
Which is Jersey resource exposes OTP profile routing?
A Jersey resource class which exposes OTP profile routing functionality as a web service. This REST API endpoint allows remotely loading, reloading, and evicting graphs on a running server. A GraphService maintains a mapping between routerIds and specific Graph objects.
Which is an example of an OpenTripPlanner request?
Example of request: http://localhost:8080/otp-rest-servlet/ws/isochrone?routerId=bordeaux&algorithm=accSampling&fromPlace=47.059,-0.880&date=2013/10/01&time=12:00:00&maxWalkDistance=1000&mode=WALK,TRANSIT&cutoffSec=1800&cutoffSec=3600 This is the primary entry point for the trip planning web service. All parameters are passed in the query string.
How to get status code for OTP rest routers?
GET http://localhost/otp-rest-servlet/ws/routers/london will return status code 200 and a brief description of the ‘london’ graph including geographic bounds, or 404 if the ‘london’ routerId is not registered. PUT http://localhost/otp-rest-servlet/ws/routers will reload the graphs for all currently registered routerIds from disk.