From cb785bdfe66c873be5fc27b3ee2b56196d6725f5 Mon Sep 17 00:00:00 2001 From: Luke Kanies Date: Wed, 13 Apr 2005 20:45:50 +0000 Subject: moving client.rb to the library tree git-svn-id: https://reductivelabs.com/svn/puppet/library/trunk@123 980ebf18-57e1-0310-9a29-db15c13687c0 --- lib/blink/client.rb | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 lib/blink/client.rb diff --git a/lib/blink/client.rb b/lib/blink/client.rb new file mode 100644 index 000000000..79c49f367 --- /dev/null +++ b/lib/blink/client.rb @@ -0,0 +1,33 @@ +#!/usr/local/bin/ruby -w + +# $Id$ + +# the available clients + +require 'blink' +require 'blink/function' + +module Blink + class ClientError < RuntimeError; end + #--------------------------------------------------------------- + class Client + attr_accessor :objects + + class Local + def callfunc(name,*args) + if function = Blink::Function[name] + return function.call(*args) + else + return nil + end + end + + def objects=(list) + list.each { |object| + # create a Blink object from the list... + } + end + end + end + #--------------------------------------------------------------- +end -- cgit