Icons
Geocode
LBS
Search
Route
Points
Miscellaneous
Index

EventListener

The EventListener class helps you to register event handlers defined by this API.
Some of the classes that inherit from this class are: Map, OverviewMap, LayersManager


Summary
The EventListener class helps you to register event handlers defined by this API.
Some of the classes that inherit from this class are: Map, OverviewMap, LayersManager
The EventListener constructor.
Adds a new listener for the specified event and call for the specified function when it occurs.
Removes all event listeners for this object.
Removes the specified event listener for the specified function.
Fires a custom event on the source object.
The specified arguments array is passed to the event handler function.

Constructors

EventListener

EventListener()

The EventListener constructor.

Methods

addListener

addListener(EventType event
function function)

Adds a new listener for the specified event and call for the specified function when it occurs.

Parameters

eventThe event type to listen to.
functionNameThe function to be called when the event occurs.

See Also

removeListener

removeAllListeners

removeAllListeners()

Removes all event listeners for this object.

See Also

addListener, removeListener

removeListener

removeListener(EventType event
function function)

Removes the specified event listener for the specified function.

Parameters

eventThe event type.
functionNameThe listener function.

See Also

addListener

triggerEvent

triggerEvent(string event
Array[] arguments)

Fires a custom event on the source object.
The specified arguments array is passed to the event handler function.

Parameters

eventThe event type.
argumentsArray of arguments to be passed.

See Also

addListener, removeListener

Inheritance: EventListener > Map
Inheritance: EventListener > OverviewMap
Inheritance: Layer > LayersCollection > LayersManager
EventListener()
The EventListener constructor.
addListener(EventType event
function function)
Adds a new listener for the specified event and call for the specified function when it occurs.
removeListener(EventType event
function function)
Removes the specified event listener for the specified function.
removeAllListeners()
Removes all event listeners for this object.
triggerEvent(string event
Array[] arguments)
Fires a custom event on the source object.
The specified arguments array is passed to the event handler function.