Modifier and Type | Method and Description |
---|---|
Path |
addEventListener(Event.Type type,
EventListener listener)
Adds a event listener to a particular event type of the object.
|
Path |
addMouseListener(MouseEvent.Type type,
MouseListener listener)
Adds a mouse listener to a particular mouse event type of the object.
|
Path |
addPopupListener(PopupEvent.Type type,
PopupListener listener)
Adds a popup listener to a particular popup event type of the object.
|
Path |
addTo(Map map)
Adds the layer to the map.
|
Path |
bindPopup(Popup popup)
Binds a given popup object to the path.
|
Path |
bindPopup(Popup popup,
PopupOptions options)
Binds a given popup object with the given options to the path.
|
Path |
bindPopup(String html)
Binds a popup with a particular HTML content to a click on this path.
|
Path |
bringToBack()
Brings the layer to the bottom of all path layers.
|
Path |
bringToFront()
Brings the layer to the top of all path layers.
|
Path |
clearAllEventListeners()
Removes all listeners to all events on the object.
|
Path |
closePopup()
Closes the path's bound popup if it is opened.
|
LatLngBounds |
getBounds()
Returns the LatLngBounds of the path.
|
Path |
openPopup()
Opens the popup previously bound by the
bindPopup method in
the given point, or in one of the path's points if not specified. |
Path |
redraw()
Redraws the layer.
|
Path |
removeEventListener(Event.Type type,
EventListener listener)
Removes a event listener to a particular event type of the object.
|
Path |
removeMouseListener(MouseEvent.Type type,
MouseListener listener)
Removes a mouse listener to a particular mouse event type of the object.
|
Path |
removePopupListener(PopupEvent.Type type,
PopupListener listener)
Removes a popup listener to a particular popup event type of the object.
|
Path |
setStyle(PathOptions options)
Changes the appearance of a Path based on the options in the
PathOptions object. |
Path |
unbindPopup()
Unbinds the popup previously bound to the path with
bindPopup . |
public Path addMouseListener(MouseEvent.Type type, MouseListener listener)
type
- The mouse event type. The types CLICK, DBLCLICK, MOUSEDOWN,
MOUSEOVER, MOUSEOUT and CONTEXTMENU are supported.listener
- The registered listener.public Path addEventListener(Event.Type type, EventListener listener)
type
- The event type. The types ADD and REMOVE are supported.listener
- The registered listener.public Path addPopupListener(PopupEvent.Type type, PopupListener listener)
type
- The popup event type. The types POPUPOPEN and POPUPCLOSE are
supported.listener
- The registered listener.public Path removeMouseListener(MouseEvent.Type type, MouseListener listener)
type
- The mouse event type. The types CLICK, DBLCLICK, MOUSEDOWN,
MOUSEOVER, MOUSEOUT and CONTEXTMENU are supported.listener
- The registered listener.public Path removeEventListener(Event.Type type, EventListener listener)
type
- The event type. The types ADD and REMOVE are supported.listener
- The registered listener.public Path removePopupListener(PopupEvent.Type type, PopupListener listener)
type
- The popup event type. The types POPUPOPEN and POPUPCLOSE are
supported.listener
- The registered listener.public Path clearAllEventListeners()
public Path setStyle(PathOptions options)
PathOptions
object.options
- path configuration optionspublic LatLngBounds getBounds()
public Path bringToFront()
public Path bringToBack()
public Path redraw()
public Path bindPopup(String html)
html
- poup HTML contentpublic Path bindPopup(Popup popup)
popup
- popup objectpublic Path bindPopup(Popup popup, PopupOptions options)
popup
- popup objectoptions
- popup configuration objectpublic Path unbindPopup()
bindPopup
.public Path openPopup()
bindPopup
method in
the given point, or in one of the path's points if not specified.public Path closePopup()
Copyright © 2017. All rights reserved.