'Get single data from Database by ``key``.
:param index_name: index to get data from
:param key: key to get
:param with_doc: if ``True`` data from **id** index will be included in output
:param with_storage: if ``True`` data from index storage will be included, otherwise just metadata.'

def get(self, index_name, key, with_doc=False, with_storage=True):

    try:
        ind = self.indexes_names[index_name]
    except KeyError:
        self.__not_opened()
        raise IndexNotFoundException(("Index    `%s`    doesn't    exists" % index_name))
    try:
        (l_key, _unk, start, size, status) = ind.get(key)
    except ElemNotFound as ex:
        raise RecordNotFound(ex)
    if ((not start) and (not size)):
        raise RecordNotFound('Not    found')
    elif (status == 'd'):
        raise RecordDeleted('Deleted')
    if (with_storage and size):
        storage = ind.storage
        data = storage.get(start, size, status)
    else:
        data = {}
    if (with_doc and (index_name != 'id')):
        storage = ind.storage
        doc = self.get('id', l_key, False)
        if data:
            data['doc'] = doc
        else:
            data = {'doc': doc}
    data['_id'] = l_key
    if (index_name == 'id'):
        data['_rev'] = _unk
    else:
        data['key'] = _unk
    return data
