code refactoring

instead of a huge file with all classes, split classes into (almost)
individual files.