Exception: Chef::Exceptions::Win32NetAPIError
- Inherits:
-
Win32APIError
- Object
- RuntimeError
- Win32APIError
- Chef::Exceptions::Win32NetAPIError
- Defined in:
- lib/chef/exceptions.rb
Instance Attribute Summary collapse
-
#error_code ⇒ Object
readonly
Returns the value of attribute error_code.
-
#msg ⇒ Object
readonly
Returns the value of attribute msg.
Instance Method Summary collapse
-
#initialize(msg, error_code) ⇒ Win32NetAPIError
constructor
A new instance of Win32NetAPIError.
Constructor Details
#initialize(msg, error_code) ⇒ Win32NetAPIError
Returns a new instance of Win32NetAPIError.
137 138 139 140 141 142 143 144 145 146 147 148 |
# File 'lib/chef/exceptions.rb', line 137 def initialize(msg, error_code) @msg = msg @error_code = error_code = "" << "---- Begin Win32 API output ----\n" << "Net Api Error Code: #{error_code}\n" << "Net Api Error Message: #{msg}\n" << "---- End Win32 API output ----\n" super() end |
Instance Attribute Details
#error_code ⇒ Object (readonly)
Returns the value of attribute error_code.
136 137 138 |
# File 'lib/chef/exceptions.rb', line 136 def error_code @error_code end |
#msg ⇒ Object (readonly)
Returns the value of attribute msg.
136 137 138 |
# File 'lib/chef/exceptions.rb', line 136 def msg @msg end |