functionality moved into class methods