Refactoring: moved model classes to separate package

Model classes were inner classes, which ensured appropriate visibilty
constraints, but arguably hampered readability and moreover resulted in
a weird issue with visibility of inner classes with inheritance (change
between JDK 1.6 and 1.7)