Packagefin.desktop.events
Classpublic class DesktopEventManager
InheritanceDesktopEventManager Inheritance Object
Subclasses Application, Window



Protected Properties
 PropertyDefined By
  _connection : DesktopConnection
DesktopEventManager
  _defaultPayload : Object
DesktopEventManager
  _eventDispatcher : EventDispatcher
DesktopEventManager
  _eventTopic : String
DesktopEventManager
Public Methods
 MethodDefined By
  
DesktopEventManager(eventTopic:String)
DesktopEventManager
  
addEventListener(type:String, listener:Function, callback:Function = null, errorCallback:Function = null):void
Registers an event listener on the specified event.
DesktopEventManager
  
dispatchEvent(event:Event):void
DesktopEventManager
  
removeEventListener(type:String, listener:Function, callback:Function = null, errorCallback:Function = null):void
Removes a previously registered event listener from the specified event
DesktopEventManager
Protected Methods
 MethodDefined By
  
createPayload(object:Object = null):Object
DesktopEventManager
  
sendMessage(action:String, payload:Object, callback:Function = null, errorCallback:Function = null):void
DesktopEventManager
Property Detail
_connectionproperty
protected var _connection:DesktopConnection

_defaultPayloadproperty 
protected var _defaultPayload:Object

_eventDispatcherproperty 
protected var _eventDispatcher:EventDispatcher

_eventTopicproperty 
protected var _eventTopic:String

Constructor Detail
DesktopEventManager()Constructor
public function DesktopEventManager(eventTopic:String)



Parameters
eventTopic:String
Method Detail
addEventListener()method
public function addEventListener(type:String, listener:Function, callback:Function = null, errorCallback:Function = null):void

Registers an event listener on the specified event.

Parameters

type:String — Event type
 
listener:Function — A listener that is called whenever an event of the specified type occurs
 
callback:Function (default = null) — A function that is called if the method succeeds
 
errorCallback:Function (default = null) — A function that is called if the method fails

createPayload()method 
protected function createPayload(object:Object = null):Object

Parameters

object:Object (default = null)

Returns
Object
dispatchEvent()method 
public function dispatchEvent(event:Event):void

Parameters

event:Event

removeEventListener()method 
public function removeEventListener(type:String, listener:Function, callback:Function = null, errorCallback:Function = null):void

Removes a previously registered event listener from the specified event

Parameters

type:String — Event type
 
listener:Function — A listener to remove
 
callback:Function (default = null) — A function that is called if the method succeeds
 
errorCallback:Function (default = null) — A function that is called if the method fails

sendMessage()method 
protected function sendMessage(action:String, payload:Object, callback:Function = null, errorCallback:Function = null):void

Parameters

action:String
 
payload:Object
 
callback:Function (default = null)
 
errorCallback:Function (default = null)