created abstract classes to clean up code