Class: Ruby::RPC::Remote

Inherits:
Object
  • Object
show all
Extended by:
DeferCalls
Includes:
RemoteCallable
Defined in:
lib/ruby/rpc/remote.rb

Instance Method Summary collapse

Methods included from DeferCalls

initialize, method_missing, method_missing

Methods included from RemoteCallable

included, #initialize

Instance Method Details

#build_remote(name, *args) ⇒ Object



12
13
14
# File 'lib/ruby/rpc/remote.rb', line 12

def build_remote name, *args
  Object.const_get(name).new *args 
end

#remote_const_get(name) ⇒ Object



8
9
10
11
# File 'lib/ruby/rpc/remote.rb', line 8

def remote_const_get name
  const = Object.const_get name
  const if const.included_modules.include? Ruby::RPC::RemoteCallable
end