Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3

...

Div
classapi-page

fluid.event.identifyListener(listener)

Section
Column
width70%

Returns the unique identifier of the given listener. If the listener has none, one will be added and returned.

Code Block
javascript
javascript
bgColorwhite
borderStylenonejavascript
fluid.event.identifyListener(listener);

File name: Fluid.js

Parameters

Span
classborderless-table

listener

(Function) description

Return Value

Span
classborderless-table

integer

The unique identifier allocated to this listener.

Column
width5%

Column

See Also


Notes

The guid of a listener can be used...

Example

Code Block
javascript
javascript
fireSpec.guids[fluid.event.identifyListener(listener)] = record;
    ...

var guid = fluid.event.identifyListener(listener);
if (fireSpec.guids[guid]) {
    var rec = fireSpec.guids[guid];
    ...
}

In this example, the identifier of the listener is used to register a record of information about the listener. Later, the guid of a listener is used to check whether or not a record exists for the listener before action is taken using it.