Module: ActiveRemote::RPC

Extended by:
ActiveSupport::Concern
Included in:
Base
Defined in:
lib/active_remote/rpc.rb

Defined Under Namespace

Modules: ClassMethods

Instance Method Summary collapse

Instance Method Details

#assign_attributes_from_rpc(response) ⇒ Object



54
55
56
57
# File 'lib/active_remote/rpc.rb', line 54

def assign_attributes_from_rpc(response)
  @attributes = self.class.build_from_rpc(response.to_hash)
  add_errors(response.errors) if response.respond_to?(:errors)
end

#remote_call(rpc_method, request_args) ⇒ Object



59
60
61
# File 'lib/active_remote/rpc.rb', line 59

def remote_call(rpc_method, request_args)
  self.class.remote_call(rpc_method, request_args)
end

#rpcObject



63
64
65
# File 'lib/active_remote/rpc.rb', line 63

def rpc
  self.class.rpc
end