Exception: Rake::Funnel::AmbiguousFileError
- Inherits:
-
StandardError
- Object
- StandardError
- Rake::Funnel::AmbiguousFileError
- Defined in:
- lib/rake/funnel/ambiguous_file_error.rb
Instance Attribute Summary collapse
-
#candidates ⇒ Object
readonly
Returns the value of attribute candidates.
-
#description ⇒ Object
readonly
Returns the value of attribute description.
-
#search_pattern ⇒ Object
readonly
Returns the value of attribute search_pattern.
-
#task_name ⇒ Object
readonly
Returns the value of attribute task_name.
Instance Method Summary collapse
-
#initialize(message, task_name, search_pattern, candidates) ⇒ AmbiguousFileError
constructor
A new instance of AmbiguousFileError.
- #to_s ⇒ Object
Constructor Details
#initialize(message, task_name, search_pattern, candidates) ⇒ AmbiguousFileError
Returns a new instance of AmbiguousFileError.
6 7 8 9 10 11 12 13 14 |
# File 'lib/rake/funnel/ambiguous_file_error.rb', line 6 def initialize(, task_name, search_pattern, candidates) description = "Could not run task '#{task_name}'. #{message}" super(description) @description = description @task_name = task_name @search_pattern = search_pattern @candidates = candidates end |
Instance Attribute Details
#candidates ⇒ Object (readonly)
Returns the value of attribute candidates.
4 5 6 |
# File 'lib/rake/funnel/ambiguous_file_error.rb', line 4 def candidates @candidates end |
#description ⇒ Object (readonly)
Returns the value of attribute description.
4 5 6 |
# File 'lib/rake/funnel/ambiguous_file_error.rb', line 4 def description @description end |
#search_pattern ⇒ Object (readonly)
Returns the value of attribute search_pattern.
4 5 6 |
# File 'lib/rake/funnel/ambiguous_file_error.rb', line 4 def search_pattern @search_pattern end |
#task_name ⇒ Object (readonly)
Returns the value of attribute task_name.
4 5 6 |
# File 'lib/rake/funnel/ambiguous_file_error.rb', line 4 def task_name @task_name end |
Instance Method Details
#to_s ⇒ Object
16 17 18 19 20 21 22 |
# File 'lib/rake/funnel/ambiguous_file_error.rb', line 16 def to_s msg = [] << inspect_description << inspect_search_pattern << inspect_candidates msg = msg.flatten.compact msg = [super.to_s] if msg.empty? msg.join("\n") end |