# Class goog.events.Listener

code »

All implemented interfaces:
  `goog.events.ListenableKey`

Simple class that stores information about a listener

## Constructor

goog.events.Listener ( listener, proxy, src, type, capture, opt_handler )

Parameters
listener: `!Function` Callback function. proxy: `Function` Wrapper for the listener that patches the event. src: `(EventTarget|goog.events.Listenable)` Source object for the event. type: `string` Event type. capture: `boolean` Whether in capture or bubble phase. opt_handler: `Object=` Object in whose context to execute the callback.

Show:Public Protected Private

## Instance Methods

code »markAsRemoved ( )

Marks this listener as removed. This also remove references held by this listener object (such as listener and event source).

## Instance Properties

code »callOnce : `boolean`

Whether to remove the listener after it has been called.

code »capture : `boolean`

Whether the listener is being called in the capture or bubble phase

code »creationStack : `string`

If monitoring the goog.events.Listener instances is enabled, stores the creation stack trace of the Disposable instance.

code »handler : `(Object|undefined)`

Optional object whose context to execute the listener in

code »key : `number`

The key of the listener.

code »listener : `Function`

Callback function.

code »proxy : `Function`

A wrapper over the original listener. This is used solely to handle native browser events (it is used to simulate the capture phase and to patch the event object).

code »removed : `boolean`

Whether the listener has been removed.

code »src : `(EventTarget|goog.events.Listenable)`

Object or node that callback is listening to

code »type : `string`

The event type.

## Compiler Constants

code »goog.events.Listener.ENABLE_MONITORING : `boolean`