openmove / OpenTripPlanner

An open source multi-modal trip planner
http://www.opentripplanner.org
Other
0 stars 0 forks source link

boundind box filter parameters for bike_rental endpoint #15

Closed stefanocudini closed 1 year ago

stefanocudini commented 1 year ago

now in bike_rental use lowerLeft,upperRight

public BikeRentalStationList getBikeRentalStations(
            @QueryParam("lowerLeft") String lowerLeft,
            @QueryParam("upperRight") String upperRight,
            @PathParam("routerId") String routerId,
            @QueryParam("locale") String locale_param) {

support minLat,minLon,maxLat,maxLon Params and lat,lon,radius like as clusters / stops endpoint

@GET
    @Path("/clusters")
    public Response getAllStopClustersInRadius (
            @QueryParam("minLat") Double minLat,
            @QueryParam("minLon") Double minLon,
            @QueryParam("maxLat") Double maxLat,
            @QueryParam("maxLon") Double maxLon,
            @QueryParam("lat")    Double lat,
            @QueryParam("lon")    Double lon,
            @QueryParam("radius") Double radius) {
zabuTNT commented 1 year ago

Now we can still use the upperRight/bottomLeft.... or a bounding box with minLat,minLon,maxLat,maxLon or lat, lon with a radius.

/otp/routers/default/bike_rental?lat=45.41948746232589&lon=10.985520570729733&radius=1000

/otp/routers/default/bike_rental?lowerLeft=45,10&upperRight=46,11

/otp/routers/default/bike_rental?minLat=45&minLon=10&maxLat=46&maxLon=11