'Create a query object by passing it the url format obtained
from the opensearch Description.'

def __init__(self, format):

    self.format = format
    self.url_parts = urlparse(format)
    self.query_string = parse_qs(self.url_parts[4])
    self.macro_map = {}
    for (key, values) in self.query_string.items():
        macro = values[0].replace(u'{', u'').replace(u'}', u'').replace(u'?', u'')
        if (macro in Query.standard_macros):
            self.macro_map[macro] = key
