Changed all class objects to typescript classes