Class: SleepingKingStudios::Docs::Errors::FileError
- Inherits:
-
Cuprum::Error
- Object
- Cuprum::Error
- SleepingKingStudios::Docs::Errors::FileError
- Defined in:
- lib/sleeping_king_studios/docs/errors/file_error.rb
Overview
Abstract base class for errors interacting with the file system.
Direct Known Subclasses
FileAlreadyExists, FileNotFound, InvalidDirectory, InvalidFile
Constant Summary collapse
- TYPE =
Short string used to identify the type of error.
'sleeping_king_studios.docs.errors.file_error'
Instance Attribute Summary collapse
-
#path ⇒ String
readonly
The invalid file or directory path.
Instance Method Summary collapse
-
#initialize(message:, path:) ⇒ FileError
constructor
A new instance of FileError.
Constructor Details
#initialize(message:, path:) ⇒ FileError
Returns a new instance of FileError.
15 16 17 18 19 |
# File 'lib/sleeping_king_studios/docs/errors/file_error.rb', line 15 def initialize(message:, path:) super(message:) @path = path end |
Instance Attribute Details
#path ⇒ String (readonly)
Returns the invalid file or directory path.
22 23 24 |
# File 'lib/sleeping_king_studios/docs/errors/file_error.rb', line 22 def path @path end |