exceptions 0.0.5 → 0.0.6

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 4190deaa464f78ca23d4a02369380b4dd37db42e
4
- data.tar.gz: bd2bda28811f03c5d3227711332eef968e753636
3
+ metadata.gz: e22bde9b588254869a161c750b9e5f9407857d69
4
+ data.tar.gz: 39ce679d0cc456ca8cdc676e8885abf806f95b7a
5
5
  SHA512:
6
- metadata.gz: 26d17a3361b35eb74181b7a11852f3e22820219a1bc5b5dbac746b0df90b2468ca5335443b232625288dcf8e3fb6862c9bb5e855e6e318405936e6684d234e52
7
- data.tar.gz: e1778b269baf6d04d1d230de6b39201b6aa77038c4572c741af3678cecab4174dac937da7b204ce948ce60e485c170e1474140962256efee445a8e96eb31d0cd
6
+ metadata.gz: 8a66bc3bd68635ed142354ced7e2289790ea357b047fa90f37df7672008f4920e41d85be492b017108c8ff848188d70c9713c140d479210b8fb4a0c3f01180a6
7
+ data.tar.gz: b8e437c1c02bff288ef0c5c1991a4a11ef15612e106fe42911952b65108b8de1a3c93a61a07442941b82548fa94eddfa942ca37dc8b721c66507839818ec294f
@@ -1,15 +1,22 @@
1
1
  module Exceptions
2
- # Public: Result represents a result of an Exception notification. It can be used
3
- # to return information about the exception.
2
+ # Public: A Result represents the result of an exception notification. It's an object
3
+ # that conforms to the following interface:
4
+ #
5
+ # `id` - The exception id from the third party service.
6
+ # `url` - A URL to view the exception in the third party service.
7
+ # `ok?` - True if the exception was successfully shuttled.
8
+ #
9
+ # This class is mostly a reference implementation but anything that conforms to the
10
+ # above interface is acceptable to return.
4
11
  class Result
5
12
  attr_reader :id
6
13
 
7
- def initialize(id)
14
+ def initialize(id = nil)
8
15
  @id = id
9
16
  end
10
17
 
11
18
  def url
12
- raise NotImplementedError
19
+ ""
13
20
  end
14
21
 
15
22
  def ok?
@@ -18,7 +25,7 @@ module Exceptions
18
25
  end
19
26
 
20
27
  # Public: BadResult can be returned when there's a failure.
21
- class BadResult
28
+ class BadResult < Result
22
29
  def ok?
23
30
  false
24
31
  end
@@ -1,3 +1,3 @@
1
1
  module Exceptions
2
- VERSION = '0.0.5'
2
+ VERSION = '0.0.6'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: exceptions
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.5
4
+ version: 0.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Eric J. Holmes