Class ElementsController


  • @RestController
    @RequestMapping("/elements")
    public class ElementsController
    extends Object
    REST controller containing the methods, which are mapped to "/elements" and used to return OSM data.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void elementsBbox​(javax.servlet.http.HttpServletRequest servletRequest, javax.servlet.http.HttpServletResponse servletResponse)
      Gives the OSM objects as GeoJSON features, which have the bounding box of the respective objects in the geometry field.
      void elementsCentroid​(javax.servlet.http.HttpServletRequest servletRequest, javax.servlet.http.HttpServletResponse servletResponse)
      Gives the OSM objects as GeoJSON features, which have the centroid of the respective objects in the geometry field.
      void elementsGeometry​(javax.servlet.http.HttpServletRequest servletRequest, javax.servlet.http.HttpServletResponse servletResponse)
      Gives the OSM objects as GeoJSON features, which have the geometry of the respective objects in the geometry field.
    • Constructor Detail

      • ElementsController

        public ElementsController()
    • Method Detail

      • elementsGeometry

        @RequestMapping(value="/geometry",
                        method={GET,POST},
                        produces="application/json")
        public void elementsGeometry​(javax.servlet.http.HttpServletRequest servletRequest,
                                     javax.servlet.http.HttpServletResponse servletResponse)
                              throws Exception
        Gives the OSM objects as GeoJSON features, which have the geometry of the respective objects in the geometry field.
        Parameters:
        servletRequest - HttpServletRequest of the incoming request
        servletResponse - HttpServletResponse of the outgoing response
        Throws:
        Exception - thrown by #extract(RequestResource, ElementsGeometry, HttpServletRequest, HttpServletResponse) extract
      • elementsBbox

        @RequestMapping(value="/bbox",
                        method={GET,POST},
                        produces="application/json")
        public void elementsBbox​(javax.servlet.http.HttpServletRequest servletRequest,
                                 javax.servlet.http.HttpServletResponse servletResponse)
                          throws Exception
        Gives the OSM objects as GeoJSON features, which have the bounding box of the respective objects in the geometry field.
        Parameters:
        servletRequest - HttpServletRequest of the incoming request
        servletResponse - HttpServletResponse of the outgoing response
        Throws:
        Exception - thrown by #extract(RequestResource, ElementsGeometry, HttpServletRequest, HttpServletResponse) extract
      • elementsCentroid

        @RequestMapping(value="/centroid",
                        method={GET,POST},
                        produces="application/json")
        public void elementsCentroid​(javax.servlet.http.HttpServletRequest servletRequest,
                                     javax.servlet.http.HttpServletResponse servletResponse)
                              throws Exception
        Gives the OSM objects as GeoJSON features, which have the centroid of the respective objects in the geometry field.
        Parameters:
        servletRequest - HttpServletRequest of the incoming request
        servletResponse - HttpServletResponse of the outgoing response
        Throws:
        Exception - thrown by #extract(RequestResource, ElementsGeometry, HttpServletRequest, HttpServletResponse) extract