Exception: OnSIP::Exceptions::OnSIPError
- Inherits:
-
StandardError
- Object
- StandardError
- OnSIP::Exceptions::OnSIPError
- Defined in:
- lib/onsip/exceptions.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#object ⇒ Object
readonly
Returns the value of attribute object.
Instance Method Summary collapse
-
#initialize(object) ⇒ OnSIPError
constructor
A new instance of OnSIPError.
- #message ⇒ Object
- #to_s ⇒ Object
Constructor Details
#initialize(object) ⇒ OnSIPError
Returns a new instance of OnSIPError.
6 7 8 |
# File 'lib/onsip/exceptions.rb', line 6 def initialize(object) @object = object end |
Instance Attribute Details
#object ⇒ Object (readonly)
Returns the value of attribute object.
4 5 6 |
# File 'lib/onsip/exceptions.rb', line 4 def object @object end |
Instance Method Details
#message ⇒ Object
10 11 12 13 14 15 16 |
# File 'lib/onsip/exceptions.rb', line 10 def if @object && @object.kind_of?(Hash) @object[:message] else @object.to_s end end |
#to_s ⇒ Object
18 19 20 |
# File 'lib/onsip/exceptions.rb', line 18 def to_s self. end |