'Create a list of all multi-query filter combinations required.
To satisfy multi-query requests ("IN" and "!=" filters), multiple queries
may be required. This code will enumerate the power-set of all multi-query
filters.
Args:
used_args: set of used positional parameters (output only variable used in
reporting for unused positional args)
args: positional arguments referenced by the proto-query in self. This
assumes the input is a tuple (and can also be called with a varargs
param).
keyword_args: dict of keyword arguments referenced by the proto-query in
self.
Returns:
A list of maps [(identifier, condition) -> value] of all queries needed
to satisfy the GQL query with the given input arguments.'

def EnumerateQueries(self, used_args, args, keyword_args):

    enumerated_queries = []
    for ((identifier, condition), value_list) in self.__filters.iteritems():
        for (operator, params) in value_list:
            value = self.__Operate(args, keyword_args, used_args, operator, params)
            self.__AddMultiQuery(identifier, condition, value, enumerated_queries)
    return enumerated_queries
