Exception: Epuber::Compiler::FileFinders::MultipleFilesFoundError
- Inherits:
-
StandardError
- Object
- StandardError
- Epuber::Compiler::FileFinders::MultipleFilesFoundError
- Defined in:
- lib/epuber/compiler/file_finders/abstract.rb
Instance Attribute Summary collapse
- #context_path ⇒ String readonly
- #files_paths ⇒ Array<String> readonly
- #groups ⇒ Array<Symbol> readonly
- #pattern ⇒ String readonly
Instance Method Summary collapse
-
#initialize(pattern, groups, context_path, files_paths) ⇒ MultipleFilesFoundError
constructor
A new instance of MultipleFilesFoundError.
- #to_s ⇒ Object
Constructor Details
#initialize(pattern, groups, context_path, files_paths) ⇒ MultipleFilesFoundError
Returns a new instance of MultipleFilesFoundError.
52 53 54 55 56 57 58 59 |
# File 'lib/epuber/compiler/file_finders/abstract.rb', line 52 def initialize(pattern, groups, context_path, files_paths) super() @pattern = pattern @groups = Array(groups) @context_path = context_path @files_paths = files_paths end |
Instance Attribute Details
#context_path ⇒ String (readonly)
45 46 47 |
# File 'lib/epuber/compiler/file_finders/abstract.rb', line 45 def context_path @context_path end |
#files_paths ⇒ Array<String> (readonly)
33 34 35 |
# File 'lib/epuber/compiler/file_finders/abstract.rb', line 33 def files_paths @files_paths end |
#groups ⇒ Array<Symbol> (readonly)
37 38 39 |
# File 'lib/epuber/compiler/file_finders/abstract.rb', line 37 def groups @groups end |
#pattern ⇒ String (readonly)
41 42 43 |
# File 'lib/epuber/compiler/file_finders/abstract.rb', line 41 def pattern @pattern end |
Instance Method Details
#to_s ⇒ Object
61 62 63 64 65 |
# File 'lib/epuber/compiler/file_finders/abstract.rb', line 61 def to_s str = "Found too many files for pattern `#{pattern}` from context path #{context_path}" str += ", file groups #{groups.map(&:inspect)}" if !groups.nil? && !groups.empty? str + ", founded files #{files_paths}" end |