class XmlrpcApi:
"""
- The XmlrpcApi class implements a basic xmlrpc (or soap) service
+ The XmlrpcApi class implements a basic xmlrpc (or soap) service
"""
protocol = None
methods, fromlist=[methods])
self.methods = methods_module.all
- self.logger = logger
-
def callable(self, method):
"""
Return a new instance of the specified method.
callablemethod = getattr(module, classname)(self)
return getattr(module, classname)(self)
except (ImportError, AttributeError):
- self.logger.log_exc("Error importing method: %s" % method)
+ logger.log_exc("Error importing method: %s" % method)
raise SfaInvalidAPIMethod(method)
def call(self, source, method, *args):
result = self.call(source, method, *args)
except SfaFault as fault:
result = fault
- self.logger.log_exc("XmlrpcApi.handle has caught Exception")
+ logger.log_exc("XmlrpcApi.handle has caught Exception")
except Exception as fault:
- self.logger.log_exc("XmlrpcApi.handle has caught Exception")
+ logger.log_exc("XmlrpcApi.handle has caught Exception")
result = SfaAPIError(fault)
# Return result