Exception: Rbeapi::Eapilib::CommandError
- Defined in:
- lib/rbeapi/eapilib.rb
Overview
A CommandError exception is raised in response to an eAPI call that returns a failure message.
Instance Attribute Summary collapse
-
#error_code ⇒ Object
readonly
Returns the value of attribute error_code.
-
#error_text ⇒ Object
readonly
Returns the value of attribute error_text.
Attributes inherited from EapiError
Instance Method Summary collapse
-
#initialize(message, code, commands = nil) ⇒ CommandError
constructor
The exception contains the eAPI error code and error text.
Methods inherited from EapiError
Constructor Details
#initialize(message, code, commands = nil) ⇒ CommandError
The exception contains the eAPI error code and error text.
88 89 90 91 92 93 94 |
# File 'lib/rbeapi/eapilib.rb', line 88 def initialize(, code, commands = nil) @error_code = code @error_text = @commands = commands = "Error [#{code}]: #{}" super() end |
Instance Attribute Details
#error_code ⇒ Object (readonly)
Returns the value of attribute error_code.
74 75 76 |
# File 'lib/rbeapi/eapilib.rb', line 74 def error_code @error_code end |
#error_text ⇒ Object (readonly)
Returns the value of attribute error_text.
75 76 77 |
# File 'lib/rbeapi/eapilib.rb', line 75 def error_text @error_text end |