Exception: GPhoto2::Error
- Inherits:
-
RuntimeError
- Object
- RuntimeError
- GPhoto2::Error
- Defined in:
- lib/gphoto2.rb
Overview
A runtime error for unsuccessful return codes.
Instance Attribute Summary collapse
- #code ⇒ Integer readonly
Instance Method Summary collapse
-
#initialize(message, code) ⇒ Error
constructor
A new instance of Error.
- #to_s ⇒ String
Constructor Details
#initialize(message, code) ⇒ Error
Returns a new instance of Error.
51 52 53 54 |
# File 'lib/gphoto2.rb', line 51 def initialize(, code) super() @code = code end |
Instance Attribute Details
#code ⇒ Integer (readonly)
47 48 49 |
# File 'lib/gphoto2.rb', line 47 def code @code end |
Instance Method Details
#to_s ⇒ String
57 58 59 |
# File 'lib/gphoto2.rb', line 57 def to_s "#{super} (#{code})" end |