Exception: Asimov::FileCannotBeOpenedError
- Inherits:
-
FileDataError
- Object
- StandardError
- Error
- RequestError
- FileDataError
- Asimov::FileCannotBeOpenedError
- Defined in:
- lib/asimov/error.rb
Overview
Error that occurs when a local file cannot be opened.
Instance Method Summary collapse
-
#initialize(file_name, system_message) ⇒ FileCannotBeOpenedError
constructor
A new instance of FileCannotBeOpenedError.
-
#message ⇒ Object
Returns the error message based on the file name and the wrapped error.
Constructor Details
#initialize(file_name, system_message) ⇒ FileCannotBeOpenedError
Returns a new instance of FileCannotBeOpenedError.
106 107 108 109 110 |
# File 'lib/asimov/error.rb', line 106 def initialize(file_name, ) super() @file_name = file_name @system_message = end |
Instance Method Details
#message ⇒ Object
Returns the error message based on the file name and the wrapped error.
115 116 117 118 |
# File 'lib/asimov/error.rb', line 115 def "The file #{@file_name} could not be opened for upload because of the " \ "following error - #{@system_message}." end |