MCPcopy Create free account
hub / github.com/ronreiter/interactive-tutorials / __init__

Method __init__

suds/client.py:97–120  ·  view source on GitHub ↗

@param url: The URL for the WSDL. @type url: str @param kwargs: keyword arguments. @see: L{Options}

(self, url, **kwargs)

Source from the content-addressed store, hash-verified

95 return sobject.__metadata__
96
97 def __init__(self, url, **kwargs):
98 """
99 @param url: The URL for the WSDL.
100 @type url: str
101 @param kwargs: keyword arguments.
102 @see: L{Options}
103 """
104 options = Options()
105 options.transport = HttpAuthenticated()
106 self.options = options
107 if 'cache' not in kwargs:
108 options.cache = ObjectCache(days=1)
109 self.set_options(**kwargs)
110 reader = DefinitionsReader(options, Definitions)
111 self.wsdl = reader.open(url)
112 plugins = PluginContainer(options.plugins)
113 plugins.init.initialized(wsdl=self.wsdl)
114 self.factory = Factory(self.wsdl)
115 self.service = ServiceSelector(self, self.wsdl.services)
116 self.sd = []
117 for s in self.wsdl.services:
118 sd = ServiceDefinition(self.wsdl, s)
119 self.sd.append(sd)
120 self.messages = dict(tx=None, rx=None)
121
122 def set_options(self, **kwargs):
123 """

Callers

nothing calls this directly

Calls 12

set_optionsMethod · 0.95
openMethod · 0.95
OptionsClass · 0.90
HttpAuthenticatedClass · 0.90
ObjectCacheClass · 0.90
DefinitionsReaderClass · 0.90
PluginContainerClass · 0.90
ServiceDefinitionClass · 0.90
ServiceSelectorClass · 0.85
initializedMethod · 0.80
FactoryClass · 0.70
appendMethod · 0.45

Tested by

no test coverage detected