Refactoring

This merge changes the underlying model to be object orientated and not static driven