Builds a soapheader for the specified I{method} using the header definition (hdef) and the specified value (object). @param method: A method name. @type method: str @param hdef: A header definition. @type hdef: tuple: (I{name}, L{xsd.sxbase.SchemaObje
(self, method, hdef, object)
| 289 | return marshaller.process(content) |
| 290 | |
| 291 | def mkheader(self, method, hdef, object): |
| 292 | """ |
| 293 | Builds a soapheader for the specified I{method} using the header |
| 294 | definition (hdef) and the specified value (object). |
| 295 | @param method: A method name. |
| 296 | @type method: str |
| 297 | @param hdef: A header definition. |
| 298 | @type hdef: tuple: (I{name}, L{xsd.sxbase.SchemaObject}) |
| 299 | @param object: The header value. |
| 300 | @type object: any |
| 301 | @return: The parameter fragment. |
| 302 | @rtype: L{Element} |
| 303 | """ |
| 304 | marshaller = self.marshaller() |
| 305 | if isinstance(object, (list, tuple)): |
| 306 | tags = [] |
| 307 | for item in object: |
| 308 | tags.append(self.mkheader(method, hdef, item)) |
| 309 | return tags |
| 310 | content = Content(tag=hdef[0], value=object, type=hdef[1]) |
| 311 | return marshaller.process(content) |
| 312 | |
| 313 | def envelope(self, header, body): |
| 314 | """ |
no test coverage detected