Exception: Ryac::Pipeline::FileNotFoundError
- Inherits:
-
StageError
- Object
- StandardError
- Error
- InputError
- StageError
- Ryac::Pipeline::FileNotFoundError
- Defined in:
- lib/ryac/pipeline/errors.rb,
sig/ryac/pipeline/errors.rbs
Overview
Raised when a required file cannot be found
Instance Attribute Summary collapse
-
#line ⇒ Integer?
readonly
Returns the value of attribute line.
-
#path ⇒ String
readonly
Returns the value of attribute path.
-
#required_from ⇒ String?
readonly
Returns the value of attribute required_from.
Instance Method Summary collapse
-
#initialize(path, required_from: nil, line: nil) ⇒ FileNotFoundError
constructor
A new instance of FileNotFoundError.
Constructor Details
#initialize(path, required_from: nil, line: nil) ⇒ FileNotFoundError
Returns a new instance of FileNotFoundError.
17 18 19 20 21 22 23 24 25 |
# File 'lib/ryac/pipeline/errors.rb', line 17 def initialize(path, required_from: nil, line: nil) @path = path @required_from = required_from @line = line = "File not found: #{path}" += " (required from #{required_from}:#{line})" if required_from && line super() end |
Instance Attribute Details
#line ⇒ Integer? (readonly)
Returns the value of attribute line.
15 16 17 |
# File 'lib/ryac/pipeline/errors.rb', line 15 def line @line end |
#path ⇒ String (readonly)
Returns the value of attribute path.
15 16 17 |
# File 'lib/ryac/pipeline/errors.rb', line 15 def path @path end |
#required_from ⇒ String? (readonly)
Returns the value of attribute required_from.
15 16 17 |
# File 'lib/ryac/pipeline/errors.rb', line 15 def required_from @required_from end |