Sha256: 88f51c75a17197d6de26c02fccb5500ee8b71c5a5865e5837b3d05200abc10be
Contents?: true
Size: 1.04 KB
Versions: 4
Compression:
Stored size: 1.04 KB
Contents
# unlike the other client classes (again, this design sucks) this class # is basically just a proxy class -- it calls its methods on the driver # and that's about it class Puppet::Network::Client::ProxyClient < Puppet::Network::Client def self.mkmethods interface = self.handler.interface namespace = interface.prefix interface.methods.each { |ary| method = ary[0] Puppet.debug "%s: defining %s.%s" % [self, namespace, method] define_method(method) { |*args| begin @driver.send(method, *args) rescue XMLRPC::FaultException => detail #Puppet.err "Could not call %s.%s: %s" % # [namespace, method, detail.faultString] #raise NetworkClientError, # "XMLRPC Error: %s" % detail.faultString raise NetworkClientError, detail.faultString end } } end end # $Id: proxy.rb 2259 2007-03-06 19:03:05Z luke $
Version data entries
4 entries across 4 versions & 1 rubygems