Get a shallow clone of this object. The clone only shares the WSDL. All other attributes are unique to the cloned object including options. @return: A shallow clone. @rtype: L{Client}
(self)
| 164 | return self.messages.get('rx') |
| 165 | |
| 166 | def clone(self): |
| 167 | """ |
| 168 | Get a shallow clone of this object. |
| 169 | The clone only shares the WSDL. All other attributes are |
| 170 | unique to the cloned object including options. |
| 171 | @return: A shallow clone. |
| 172 | @rtype: L{Client} |
| 173 | """ |
| 174 | class Uninitialized(Client): |
| 175 | def __init__(self): |
| 176 | pass |
| 177 | clone = Uninitialized() |
| 178 | clone.options = Options() |
| 179 | cp = Unskin(clone.options) |
| 180 | mp = Unskin(self.options) |
| 181 | cp.update(deepcopy(mp)) |
| 182 | clone.wsdl = self.wsdl |
| 183 | clone.factory = self.factory |
| 184 | clone.service = ServiceSelector(clone, self.wsdl.services) |
| 185 | clone.sd = self.sd |
| 186 | clone.messages = dict(tx=None, rx=None) |
| 187 | return clone |
| 188 | |
| 189 | def __str__(self): |
| 190 | s = ['\n'] |
no test coverage detected