Added an abstract mapper to make mapper implementations easier.