Trying to identify class of event target

I entered the following line into my event handler function:


I did a html5 build and the result from a mouse click on an object is:

FuelingStationMainScreen.hx:113: {
name : [StationMarker]

Why does Type.getClass return something with a name but Type.getClassName returns null?
How can I get the class and/or class name of the event target?


Try Type.getClassName(Type.getClass(event.currentTarget))

That works, thanks. It seems logical to me that if you can get the class of an object directly, you should be able to also get the class name of an object directly.

Yeah, I’ve made this mistake a lot