Documentation
Reference
2.1.50 (current version)
collection
interactivityModel
Interfaces

IEventGroup

A group of event listeners.

Constructor | Methods

Constructor

IEventGroup()

Methods

NameReturnsDescription
add(types, callback[, context[, priority]])

IEventGroup

Adds an event listener.

remove(types, callback[, context[, priority]])

IEventGroup

Deletes an event listener from the group.

removeAll()

IEventGroup

Deletes all event listeners from the group.

Methods details

add

Adds an event listener.

Returns self-reference.

Parameters:

ParameterDefault valueDescription
types*
[no-highlight[

* Mandatory parameter/option.

]no-highlight]

Type: String[][]|String[]

Type or array of types for the event.

callback*
[no-highlight[

* Mandatory parameter/option.

]no-highlight]

Type: Function

Handler function. The event object is passed to the function as a parameter.

context

Type: Object

Context for the handler function.

priority 0

Type: Integer

Subscription priority.

* Mandatory parameter/option.

remove

Deletes an event listener from the group.

Returns self-reference.

Parameters:

ParameterDefault valueDescription
types*
[no-highlight[

* Mandatory parameter/option.

]no-highlight]

Type: String[][]|String[]

Type or array of types for the events.

callback*
[no-highlight[

* Mandatory parameter/option.

]no-highlight]

Type: Function

Handler function. The event object is passed to the function as a parameter.

context

Type: Object

Context for the handler function.

priority 0

Type: Integer

Subscription priority.

* Mandatory parameter/option.

removeAll

{IEventGroup} removeAll()

Deletes all event listeners from the group.

Returns self-reference.