A bunch of changes

Code converted into std=c++11
MappingWriter with unit tests impemented