Adding a class to handle the code