fix java issue on haxe 3.1