Move classes into packages

Fixes #2