the hex class definition

class member function definitions