some methods moved into appropriate class
refactored
refactored