Class GeolocItemPolygon

java.lang.Object
fr.paris.lutece.plugins.leaflet.business.GeolocItemPolygon

public class GeolocItemPolygon extends Object
A geoloc item with methods to translate to/from geojson and to XML
  • Field Details

  • Constructor Details

    • GeolocItemPolygon

      public GeolocItemPolygon()
  • Method Details

    • setGeometry

      public void setGeometry(Map<String,Object> geometry)
      Sets the Geometry
      Parameters:
      geometry - the geometry
    • setProperties

      public void setProperties(Map<String,Object> properties)
      Sets the Properties
      Parameters:
      properties - the geometry
    • getType

      public String getType()
      Returns the Type
      Returns:
      The type
    • getProperties

      public Map<String,Object> getProperties()
      Returns the Properties
      Returns:
      The properties
    • getGeometry

      public Map<String,Object> getGeometry()
      Returns the Geometry
      Returns:
      The geometry
    • getLonLat

      public List<Double> getLonLat()
      Returns the LonLat
      Returns:
      The LonLat
    • getLon

      public double getLon()
      Returns the Lon
      Returns:
      The Lon
    • getLat

      public double getLat()
      Returns the Lat
      Returns:
      The Lat
    • getIcon

      public String getIcon()
      Returns the Icon
      Returns:
      The icon
    • getLayer

      public String getLayer()
      Returns the Layer
      Returns:
      The layer
    • setIcon

      public void setIcon(String icon)
      Sets the Icon
      Parameters:
      icon - the icon
    • toJSON

      public String toJSON()
      Writes the geojson to a String
      Returns:
      The geojseon String
    • toXML

      public String toXML()
      Writes the xml to a String. This is a non standard representation.
      Returns:
      The xml String
    • fromJSON

      public static GeolocItemPolygon fromJSON(String strJson) throws IOException
      Parses a geojson string to build a GeolocItem Object.
      Returns:
      The geolocItem object
      Throws:
      IOException
    • getTypegeometry

      public String getTypegeometry()
    • setTypegeometry

      public void setTypegeometry(String _typegeometry)