implimenting class definition generation on JavaScriptGenerator