Refactored classes to try and get most of them under 10 LOC