tasks/lib/types.js
function (eventName, handler)
  {
    if (!this._events[eventName])
      this._events[eventName] = [];
    this._events[eventName].push (handler);
  }
function (eventName, handler)
  {
    if (!this._events[eventName])
      this._events[eventName] = [];
    this._events[eventName].push (handler);
  }
function ( eventName , handler ) { if ( ! this . _events [ eventName ] ) this . _events [ eventName ] = [ ] ; this . _events [ eventName ] . push ( handler ) ; }
Registers an event handler.
@param {ContextEvent} eventName
@param {function()} handler
Registers an event handler .