use extend to inherit from base class