From ae95e8f8aaff19d29097acf34975f1669ed1ab30 Mon Sep 17 00:00:00 2001 From: Gregory Warnes Date: Tue, 23 Dec 2003 07:21:27 +0000 Subject: [PATCH] - rename loadFromStream's 'file' argument to 'stream' to make it clear that the stream need not be a file. --- WSDLTools.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/WSDLTools.py b/WSDLTools.py index a7b8403..d2e71b7 100755 --- a/WSDLTools.py +++ b/WSDLTools.py @@ -21,14 +21,14 @@ class WSDLReader: # strategy or other optimizations. Because application needs vary # so widely, we don't try to provide any caching by default. - def loadFromStream(self, file, name=None): - """Return a WSDL instance loaded from a file object.""" - document = DOM.loadDocument(file) + def loadFromStream(self, stream, name=None): + """Return a WSDL instance loaded from a stream object.""" + document = DOM.loadDocument(stream) wsdl = WSDL() if name: wsdl.location = name - elif hasattr(file, 'name'): - wsdl.location = file.name + elif hasattr(stream, 'name'): + wsdl.location = stream.name wsdl.load(document) return wsdl