Refactoring, adding attr_readers and attr_accessors