'Deserialize a string to a dictionary.
The string must be in the format of a supported MIME type.'

def deserialize(self, datastring, content_type):

    try:
        return self.get_deserialize_handler(content_type).deserialize(datastring)
    except Exception:
        raise webob.exc.HTTPBadRequest(_('Could    not    deserialize    data'))
