Class MapDataWithGeometryParser

  • All Implemented Interfaces:
    de.westnordost.osmapi.ApiResponseReader<java.lang.Void>

    public class MapDataWithGeometryParser
    extends de.westnordost.osmapi.common.XmlParser
    implements de.westnordost.osmapi.ApiResponseReader<java.lang.Void>
    A map data parser that also parses the geometry of elements as outputted by queries with the geom modificator (for example out body geom;).

    It supports the out statements skel, body, tags and meta but never includes the changeset and user info because it includes personally identifying information and Overpass API is a public API.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected void onEndElement()  
      protected void onStartElement()  
      java.lang.Void parse​(java.io.InputStream in)  
      • Methods inherited from class de.westnordost.osmapi.common.XmlParser

        doParse, getAttribute, getBooleanAttribute, getByteAttribute, getDoubleAttribute, getFloatAttribute, getIntAttribute, getLongAttribute, getName, getParentName, getText, onTextNode
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • MapDataWithGeometryParser

        public MapDataWithGeometryParser​(@NotNull
                                         MapDataWithGeometryHandler handler,
                                         @NotNull
                                         de.westnordost.osmapi.map.MapDataFactory factory)
    • Method Detail

      • parse

        public java.lang.Void parse​(@NotNull
                                    java.io.InputStream in)
                             throws java.io.IOException
        Specified by:
        parse in interface de.westnordost.osmapi.ApiResponseReader<java.lang.Void>
        Throws:
        java.io.IOException
      • onStartElement

        protected void onStartElement()
                               throws java.text.ParseException
        Specified by:
        onStartElement in class de.westnordost.osmapi.common.XmlParser
        Throws:
        java.text.ParseException
      • onEndElement

        protected void onEndElement()
        Specified by:
        onEndElement in class de.westnordost.osmapi.common.XmlParser