Module: ActiveRemote::RPC
Defined Under Namespace
Modules: ClassMethods
Instance Method Summary collapse
- #assign_attributes_from_rpc(response) ⇒ Object
- #remote_call(rpc_method, request_args) ⇒ Object
- #rpc ⇒ Object
Instance Method Details
#assign_attributes_from_rpc(response) ⇒ Object
55 56 57 58 |
# File 'lib/active_remote/rpc.rb', line 55 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
60 61 62 |
# File 'lib/active_remote/rpc.rb', line 60 def remote_call(rpc_method, request_args) self.class.remote_call(rpc_method, request_args) end |
#rpc ⇒ Object
64 65 66 |
# File 'lib/active_remote/rpc.rb', line 64 def rpc self.class.rpc end |