Class: Exceptions::Backends::Multi
- Inherits:
-
Exceptions::Backend
- Object
- Exceptions::Backend
- Exceptions::Backends::Multi
- Defined in:
- lib/exceptions/backends/multi.rb
Overview
Public: Multi is an implementation of the Backend interface for wrapping multiple backends as a single Backend.
Instance Attribute Summary collapse
-
#backends ⇒ Object
readonly
Returns the value of attribute backends.
Instance Method Summary collapse
-
#initialize(*backends) ⇒ Multi
constructor
A new instance of Multi.
- #notify(exception, options = {}) ⇒ Object
Methods inherited from Exceptions::Backend
#clear_context, #context, #rack_exception
Constructor Details
#initialize(*backends) ⇒ Multi
Returns a new instance of Multi.
8 9 10 |
# File 'lib/exceptions/backends/multi.rb', line 8 def initialize(*backends) @backends = backends end |
Instance Attribute Details
#backends ⇒ Object (readonly)
Returns the value of attribute backends.
6 7 8 |
# File 'lib/exceptions/backends/multi.rb', line 6 def backends @backends end |
Instance Method Details
#notify(exception, options = {}) ⇒ Object
12 13 14 15 16 |
# File 'lib/exceptions/backends/multi.rb', line 12 def notify(exception, = {}) backends.each do |backend| backend.notify exception, end end |