Here is the code for the email class