simplerpc 0.2.3 → 0.2.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/simplerpc/client.rb +19 -1
  3. metadata +5 -5
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 52022e8918debc2f49826eece8e11e9574e2f95d
4
- data.tar.gz: 2f0e477006ea17a446215935cc3e7c87269a0a66
3
+ metadata.gz: fc9653218ecb394370d5c9a4a9ddc57c496b7124
4
+ data.tar.gz: f6c2cbc647bc3573dfb471c2c032e032245369fb
5
5
  SHA512:
6
- metadata.gz: c593b4f3e3214db8d174f24acff198434ec9239b226baa8fa34ac11a49c6cb85c3c52c49facdad515d9c84a78cde459893d78de60af956bbb03e28f653dd37f9
7
- data.tar.gz: 3805c2bea6266ef4312f4984358d47ad003562ddb60cdc1cb0024dcf2689f5f9c8f9dc26345e65500e0f0ece2c1e7518c7d73e4c7295f5aac75b6047e11e0e48
6
+ metadata.gz: 071d0a5ce8fc194496c4253dc8ec2d4323e00ea2b66af41e8368639b84fab5545eabe76f3bbe36ec338b3d3a589f31bc874cb130e1f661e7ae61e19865b7ccfd
7
+ data.tar.gz: 27c9bdff6148aa3849a6d3707aef01351373c4f76b900c33194ab9a447c609479facb45d2e988ba589fc840248622676dd5aba487b1ff67d6e61f9343721abe2
@@ -1,4 +1,4 @@
1
- require 'socket' # Sockets are in standard library
1
+ require 'socket'
2
2
  require 'simplerpc/socket_protocol'
3
3
 
4
4
  # rubocop:disable LineLength
@@ -15,6 +15,24 @@ module SimpleRPC
15
15
  #
16
16
  # The message is set to the server's exception class.
17
17
  class RemoteException < Exception
18
+
19
+ attr_reader :remote_exception
20
+
21
+ def initialize(exception)
22
+ super(exception)
23
+ @remote_exception = exception
24
+ end
25
+
26
+ # Return the backtrace from the original (remote)
27
+ # exception
28
+ def backtrace
29
+ @remote_exception.backtrace
30
+ end
31
+
32
+ # Return a string representing the remote exception
33
+ def to_s
34
+ @remote_exception.to_s
35
+ end
18
36
  end
19
37
 
20
38
  # The superclass of a proxy object
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: simplerpc
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.3
4
+ version: 0.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stephen Wattam
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-08-15 00:00:00.000000000 Z
11
+ date: 2014-01-20 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: A very simple and fast RPC library
14
14
  email: stephenwattam@gmail.com
@@ -16,10 +16,10 @@ executables: []
16
16
  extensions: []
17
17
  extra_rdoc_files: []
18
18
  files:
19
- - lib/simplerpc/client.rb
20
- - lib/simplerpc/server.rb
21
19
  - lib/simplerpc/encryption.rb
20
+ - lib/simplerpc/server.rb
22
21
  - lib/simplerpc/socket_protocol.rb
22
+ - lib/simplerpc/client.rb
23
23
  - ./lib/simplerpc.rb
24
24
  - LICENSE
25
25
  homepage: http://stephenwattam.com/projects/simplerpc
@@ -42,7 +42,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
42
42
  version: '0'
43
43
  requirements: []
44
44
  rubyforge_project:
45
- rubygems_version: 2.0.3
45
+ rubygems_version: 2.0.14
46
46
  signing_key:
47
47
  specification_version: 4
48
48
  summary: Simple RPC library