Exception: Dirwatch::FileEmptyError

Inherits:
IOError
  • Object
show all
Includes:
UserFriendlyError
Defined in:
lib/dirwatch/errors.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from UserFriendlyError

#user_friendly_message

Constructor Details

#initialize(filename, msg = nil) ⇒ FileEmptyError

Returns a new instance of FileEmptyError.



22
23
24
25
# File 'lib/dirwatch/errors.rb', line 22

def initialize filename, msg = nil
  super msg || "The file #{filename.inspect} is empty"
  @filename = filename
end

Instance Attribute Details

#filenameObject (readonly)

Returns the value of attribute filename.



21
22
23
# File 'lib/dirwatch/errors.rb', line 21

def filename
  @filename
end