refactoring base class usage