All Superinterfaces:
Serializable
All Known Subinterfaces:
MapOptions
All Known Implementing Classes:
DefaultMapOptions

public interface MapStateOptions extends Serializable
Leaflet map state options
Since:
2020-03-06
Version:
1.0
Author:
Gabor Kokeny Email: kokeny19@gmail.com
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the geographical bounds visible in the current map view
    Returns the initial geographic center of the map.
    Returns the geographical bounds the map view is restricted to.
    Returns the maximum zoom level of the map.
    Returns the minimum zoom level of the map.
    Returns the initial map zoom level.
    void
    Sets a map view that contains the given geographical bounds with the maximum zoom level possible.
    void
    setCenter(LatLng center)
    Initial geographic center of the map
    void
    When this option is set, the map restricts the view to the given geographical bounds, bouncing the user back if the user tries to pan outside the view.
    void
    Maximum zoom level of the map.
    void
    Minimum zoom level of the map.
    void
    Initial map zoom level
  • Method Details

    • getCenter

      LatLng getCenter()
      Returns the initial geographic center of the map.
      Returns:
      the geographic center of the map
    • setCenter

      void setCenter(LatLng center)
      Initial geographic center of the map
      Parameters:
      center - the intial center of the map
    • getZoom

      Integer getZoom()
      Returns the initial map zoom level.
      Returns:
      the initial map zoom level
    • setZoom

      void setZoom(Integer zoom)
      Initial map zoom level
      Parameters:
      zoom - the initial map zoom level
    • setBounds

      void setBounds(LatLngBounds bounds)
      Sets a map view that contains the given geographical bounds with the maximum zoom level possible.
      Parameters:
      bounds - the geographical bounds of the map
    • getBounds

      LatLngBounds getBounds()
      Returns the geographical bounds visible in the current map view
      Returns:
      the geographical bounds of the map
    • getMinZoom

      Integer getMinZoom()
      Returns the minimum zoom level of the map.
      Returns:
      the minimum zoom level of the map
    • setMinZoom

      void setMinZoom(Integer minZoom)
      Minimum zoom level of the map. If not specified and at least one GridLayer or TileLayer is in the map, the lowest of their minZoom options will be used instead.
      Parameters:
      minZoom - the minimum zoom level of the map
    • getMaxZoom

      Integer getMaxZoom()
      Returns the maximum zoom level of the map.
      Returns:
      the maximum zoom level of the map
    • setMaxZoom

      void setMaxZoom(Integer maxZoom)
      Maximum zoom level of the map. If not specified and at least one GridLayer or TileLayer is in the map, the highest of their maxZoom options will be used instead.
      Parameters:
      maxZoom - the maximum zoom level of the map
    • getMaxBounds

      LatLngBounds getMaxBounds()
      Returns the geographical bounds the map view is restricted to.
      Returns:
      the maximum geographical bounds of the map view
    • setMaxBounds

      void setMaxBounds(LatLngBounds maxBounds)
      When this option is set, the map restricts the view to the given geographical bounds, bouncing the user back if the user tries to pan outside the view. To set the restriction dynamically, use setMaxBounds method.
      Parameters:
      maxBounds - restricts the view to the given bounds