Class: OpenVASOMP::OMPError
- Inherits:
-
RuntimeError
- Object
- RuntimeError
- OpenVASOMP::OMPError
- Defined in:
- lib/ovas.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#reason ⇒ Object
Returns the value of attribute reason.
-
#req ⇒ Object
Returns the value of attribute req.
Instance Method Summary collapse
-
#initialize(req, reason = '') ⇒ OMPError
constructor
A new instance of OMPError.
- #to_s ⇒ Object
Constructor Details
#initialize(req, reason = '') ⇒ OMPError
Returns a new instance of OMPError.
19 20 21 22 |
# File 'lib/ovas.rb', line 19 def initialize(req, reason = '') self.req = req self.reason = reason end |
Instance Attribute Details
#reason ⇒ Object
Returns the value of attribute reason.
18 19 20 |
# File 'lib/ovas.rb', line 18 def reason @reason end |
#req ⇒ Object
Returns the value of attribute req.
18 19 20 |
# File 'lib/ovas.rb', line 18 def req @req end |
Instance Method Details
#to_s ⇒ Object
23 24 25 |
# File 'lib/ovas.rb', line 23 def to_s "OpenVAS OMP: #{self.reason}" end |