'@param url: A URL to the WSDL.
@type url: str
@param options: An options dictionary.
@type options: L{options.Options}'

def __init__(self, url, options):

    log.debug('reading    wsdl    at:    %s    ...', url)
    reader = DocumentReader(options)
    d = reader.open(url)
    root = d.root()
    WObject.__init__(self, root)
    self.id = objid(self)
    self.options = options
    self.url = url
    self.tns = self.mktns(root)
    self.types = []
    self.schema = None
    self.children = []
    self.imports = []
    self.messages = {}
    self.port_types = {}
    self.bindings = {}
    self.services = []
    self.add_children(self.root)
    self.children.sort()
    pmd = self.__metadata__.__print__
    pmd.excludes.append('children')
    pmd.excludes.append('wsdl')
    pmd.wrappers['schema'] = repr
    self.open_imports()
    self.resolve()
    self.build_schema()
    self.set_wrapped()
    for s in self.services:
        self.add_methods(s)
    log.debug("wsdl    at    '%s'    loaded:\n%s", url, self)
