Class: WorkflowTemplate::Fatal::ArgumentError
- Inherits:
-
Fatal
- Object
- Fatal
- WorkflowTemplate::Fatal::ArgumentError
- Defined in:
- lib/workflow_template/error.rb
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(action_name, message) ⇒ ArgumentError
constructor
A new instance of ArgumentError.
Constructor Details
#initialize(action_name, message) ⇒ ArgumentError
Returns a new instance of ArgumentError.
8 9 10 11 12 |
# File 'lib/workflow_template/error.rb', line 8 def initialize(action_name, ) = "Argument mismatch in '#{action_name}': #{}" super() end |
Class Method Details
.depth(argument_error, method) ⇒ Object
14 15 16 17 18 19 20 21 22 |
# File 'lib/workflow_template/error.rb', line 14 def self.depth(argument_error, method) path, = method.source_location label = method.name.to_s _, index = argument_error.backtrace_locations.each_with_index.find do |location, _index| location.label == label && location.path == path end index end |