@JsType(isNative=true,
namespace="<global>")
public class L
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
L.control
The Class control.
|
static class |
L.CRS
The Class CRS.
|
static class |
L.Projection |
static class |
L.tileLayer
Used to load and display tile layers on the map.
|
static class |
L.Transformation
The Class Transformation.
|
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
version
A constant that represents the Leaflet version in use.
|
Modifier and Type | Method and Description |
---|---|
static Bounds |
bounds(Point topLeft,
Point bottomRight)
Represents a rectangular area in pixel coordinates.
|
static Canvas |
canvas(RendererOptions options)
Creates a SVG renderer with the given options.
|
static Circle |
circle(LatLng latlng,
CircleOptions options)
A class for drawing circle overlays on a map.
|
static CircleMarker |
circleMarker(LatLng latlng,
CircleOptions options)
A circle of a fixed size with radius specified in pixels.
|
static Control |
control(ControlOptions options)
The base class for all Leaflet controls.
|
static DivIcon |
divIcon(DivIconOptions options)
Represents a lightweight icon for markers that uses a simple div element instead of an image.
|
static FeatureGroup |
featureGroup(Layer[] layers)
Extended layerGroup that also has mouse events (propagated from members of the group) and a shared bindPopup method.
|
static GeoJSON |
geoJSON(com.google.gwt.core.client.JavaScriptObject geojson,
GeoJSONOptions options)
Represents a GeoJSON object or an array of GeoJSON objects.
|
static GridLayer |
gridLayer(GridLayerOptions options)
Creates a new instance of GridLayer with the supplied options.
|
static Icon |
icon(IconOptions options)
Represents an icon to provide when creating a marker.
|
static ImageOverlay |
imageOverlay(java.lang.String imageUrl,
LatLngBounds bounds,
ImageOverlayOptions options)
Used to load and display a single image over specific bounds of the map, implements ILayer interface.
|
static LatLng |
latLng(double latitude,
double longitude)
Represents a geographical point with a certain latitude and longitude.
|
static LatLngBounds |
latLngBounds(LatLng southWest,
LatLng northEast)
Represents a rectangular geographical area on a map.
|
static LayerGroup |
layerGroup(Layer[] layers)
Used to group several layers and handle them as one.
|
static Map |
map(HTMLElement element,
MapOptions options)
The central class of the API — it is used to create a map on a page and manipulate it.
|
static Map |
map(java.lang.String id,
MapOptions options)
The central class of the API — it is used to create a map on a page and manipulate it.
|
static Marker |
marker(LatLng latlng,
MarkerOptions options)
Marker is used to put markers on the map.
|
static Point |
point(double x,
double y,
java.lang.Boolean round)
Represents a point with x and y coordinates in pixels.
|
static Polygon |
polygon(LatLng[][] latlngs,
PolylineOptions options)
A class for drawing polygon overlays on a map.
|
static Polyline |
polyline(LatLng[][] latlngs,
PolylineOptions options)
A class for drawing polyline overlays on a map.
|
static Popup |
popup(PopupOptions options,
Layer source)
Used to open popups in certain places of the map.
|
static Rectangle |
rectangle(LatLngBounds bounds,
PathOptions options)
A class for drawing rectangle overlays on a map.
|
static SVG |
svg(RendererOptions options)
Creates a SVG renderer with the given options.
|
static TileLayer |
tileLayer(java.lang.String urlTemplate,
TileLayerOptions options)
Used to load and display tile layers on the map, implements ILayer interface.
|
static Tooltip |
tooltip(TooltipOptions options,
Layer source)
Instantiates a Tooltip object given an optional options object that describes its appearance and location and an optional source object that is used to tag the tooltip with a reference to the Layer to which it refers.
|
static L.Transformation |
transformation(double a,
double b,
double c,
double d)
Represents an affine transformation: a set of coefficients a, b, c, d for transforming a point of a form (x, y) into (a*x + b, c*y + d) and doing the reverse.
|
@JsProperty public static java.lang.String version
public static Map map(java.lang.String id, MapOptions options)
id
- the id of the elementoptions
- map optionspublic static Map map(HTMLElement element, MapOptions options)
element
- the elementoptions
- map optionspublic static Marker marker(LatLng latlng, MarkerOptions options)
latlng
- the geographical pointsoptions
- the marker optionspublic static Popup popup(PopupOptions options, Layer source)
options
- the pop up optionssource
- the popup source Layerpublic static TileLayer tileLayer(java.lang.String urlTemplate, TileLayerOptions options)
urlTemplate
- the url templateoptions
- the optionspublic static ImageOverlay imageOverlay(java.lang.String imageUrl, LatLngBounds bounds, ImageOverlayOptions options)
imageUrl
- the image urlbounds
- the boundsoptions
- the ImageOverlay optionspublic static Polyline polyline(LatLng[][] latlngs, PolylineOptions options)
latlngs
- the latlngs arrayoptions
- the Polyline optionspublic static Polygon polygon(LatLng[][] latlngs, PolylineOptions options)
latlngs
- the latlngs arrayoptions
- the Polygon optionspublic static Rectangle rectangle(LatLngBounds bounds, PathOptions options)
bounds
- the bounds of the rectangleoptions
- Rectangle the optionspublic static Circle circle(LatLng latlng, CircleOptions options)
latlng
- the latlng of the circle on the mapoptions
- the Circle optionspublic static CircleMarker circleMarker(LatLng latlng, CircleOptions options)
latlng
- the latlngoptions
- the CircleMarker optionspublic static LayerGroup layerGroup(Layer[] layers)
layers
- the layers arraypublic static FeatureGroup featureGroup(Layer[] layers)
layers
- the layerspublic static GeoJSON geoJSON(com.google.gwt.core.client.JavaScriptObject geojson, GeoJSONOptions options)
geojson
- the geojson object in GeoJSON format to display on the map (you can alternatively add it later with addData method) and an options object.options
- the GeoJSON optionspublic static LatLng latLng(double latitude, double longitude)
latitude
- the Latitude in degrees.longitude
- Longitude in degrees.public static LatLngBounds latLngBounds(LatLng southWest, LatLng northEast)
southWest
- the south west pointnorthEast
- the north east pointpublic static Point point(double x, double y, java.lang.Boolean round)
x
- the x coordinatey
- the y coordinateround
- the roundpublic static Bounds bounds(Point topLeft, Point bottomRight)
topLeft
- The top left corner of the rectangle.bottomRight
- The bottom right corner of the rectangle.public static Icon icon(IconOptions options)
options
- the Icon optionspublic static DivIcon divIcon(DivIconOptions options)
options
- the DivIcon optionspublic static Control control(ControlOptions options)
control.addTo(map);
// or
map.addControl(control);
options
- the Control optionspublic static L.Transformation transformation(double a, double b, double c, double d)
a
- the ab
- the bc
- the cd
- the dpublic static Tooltip tooltip(TooltipOptions options, Layer source)
options
- the tooltip optionssource
- the source layerpublic static Canvas canvas(RendererOptions options)
options
- the canvas optionspublic static SVG svg(RendererOptions options)
options
- the canvas optionspublic static GridLayer gridLayer(GridLayerOptions options)
options
- the options