'Run through all the "in" statements on top of target_str and return a list
according to the class __init__ documentation.
:param target_str: The target string where the in statements are
going to be applied.'

def query(self, target_str):

    result = []
    if isinstance(target_str, unicode):
        target_str = target_str.encode(DEFAULT_ENCODING)
    query_result_list = self._index.query(target_str)
    for query_result in query_result_list:
        if (len(query_result[1]) == 1):
            result.append(list(query_result[1:][0])[0])
        else:
            result.append(list(query_result[1:][0]))
    return result
