DATACOUCH-12: Refactor mapping layer to accomodate complex types.

This changeset is a complete refactor of the mapping layer to make
sure that _class complex type mapping works. It also decouples
the actual JSON mapping and abstracts it into a CouchbaseDocument
mapping. This ensures forward compatibility by potentially swapping
out JSON to a different format.