Exception: Howler::Message::Error
- Inherits:
-
Exception
- Object
- Exception
- Howler::Message::Error
- Defined in:
- lib/howler/exceptions/error.rb
Instance Attribute Summary collapse
-
#message ⇒ Object
Returns the value of attribute message.
Instance Method Summary collapse
- #info ⇒ Object
-
#initialize(options = {}) ⇒ Error
constructor
A new instance of Error.
Constructor Details
#initialize(options = {}) ⇒ Error
Returns a new instance of Error.
5 6 7 8 9 10 11 |
# File 'lib/howler/exceptions/error.rb', line 5 def initialize( = {}) @info = {} .each do |key, value| @info[key.to_s] = value end end |
Instance Attribute Details
#message ⇒ Object
Returns the value of attribute message.
3 4 5 |
# File 'lib/howler/exceptions/error.rb', line 3 def @message end |
Instance Method Details
#info ⇒ Object
13 14 15 16 17 18 19 20 21 22 23 |
# File 'lib/howler/exceptions/error.rb', line 13 def info @info.merge!( 'backtrace' => self.backtrace[0..7] ) if self.backtrace && !@info['backtrace'] @info.merge!( 'message' => self. ) unless @info['message'] @info end |