code for the classes