So, after making a good progression, seems like I have hit some kind of a road block with EventHandler.hx
After doing some research I figured out that there is something called AS3-Signals(an alternate Event system) which should be an equivalent and haxe must handle it accordingly. But in my case thats not happening.
in haxe : -
public var onJoin = new EventHandler<Void->Void>();
public var onStateChange = new EventHandler<Dynamic->Void>();
public var onError = new EventHandler<Int->String->Void>();
public var onLeave = new EventHandler<Void->Void>();
after compilation to swf/swc they all become of Type array
public var onStateChange:Array;
public var onLeave:Array;
public var onJoin:Array;
public var onError:Array;
Also if you check
EventHandler.hx, they have used inline functions and operator overloading, which I have never used in AS3, but I know its possible.
I would really appreciate if anyone can help me understand on these things!