Exception: Asimov::FileCannotBeOpenedError

Inherits:
FileDataError show all
Defined in:
lib/asimov/error.rb

Overview

Error that occurs when a local file cannot be opened.

Instance Method Summary collapse

Constructor Details

#initialize(file_name, system_message) ⇒ FileCannotBeOpenedError

Returns a new instance of FileCannotBeOpenedError.



84
85
86
87
88
# File 'lib/asimov/error.rb', line 84

def initialize(file_name, system_message)
  super()
  @file_name = file_name
  @system_message = system_message
end

Instance Method Details

#messageObject



90
91
92
93
# File 'lib/asimov/error.rb', line 90

def message
  "The file #{@file_name} could not be opened for upload because of the " \
    "following error - #{@system_message}."
end