Total restructuring of the MapDb, in an attempt to make the codebase easier to work with. Now it compiles.... MOving on to check the tests.