Exception: Chef::ChefFS::FileSystem::OperationFailedError
- Inherits:
-
FileSystemError
- Object
- StandardError
- FileSystemError
- Chef::ChefFS::FileSystem::OperationFailedError
- Defined in:
- lib/chef/chef_fs/file_system/exceptions.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#operation ⇒ Object
readonly
Returns the value of attribute operation.
Attributes inherited from FileSystemError
Instance Method Summary collapse
-
#initialize(operation, entry, cause = nil, reason = nil) ⇒ OperationFailedError
constructor
A new instance of OperationFailedError.
- #message ⇒ Object
Constructor Details
#initialize(operation, entry, cause = nil, reason = nil) ⇒ OperationFailedError
Returns a new instance of OperationFailedError.
48 49 50 51 |
# File 'lib/chef/chef_fs/file_system/exceptions.rb', line 48 def initialize(operation, entry, cause = nil, reason = nil) super(entry, cause, reason) @operation = operation end |
Instance Attribute Details
#operation ⇒ Object (readonly)
Returns the value of attribute operation.
61 62 63 |
# File 'lib/chef/chef_fs/file_system/exceptions.rb', line 61 def operation @operation end |
Instance Method Details
#message ⇒ Object
53 54 55 56 57 58 59 |
# File 'lib/chef/chef_fs/file_system/exceptions.rb', line 53 def if cause && cause.is_a?(Net::HTTPExceptions) && cause.response.code == "400" "#{super} cause: #{cause.response.body}" else super end end |