some more object oriented design v.2