Class: SourceReaders::Flat
- Inherits:
-
Object
- Object
- SourceReaders::Flat
- Defined in:
- lib/source_readers/flat.rb
Instance Attribute Summary collapse
-
#data_files ⇒ Object
readonly
Returns the value of attribute data_files.
-
#libraries ⇒ Object
readonly
Returns the value of attribute libraries.
-
#metadata ⇒ Object
readonly
Returns the value of attribute metadata.
-
#tests ⇒ Object
readonly
Returns the value of attribute tests.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(target, files) ⇒ Flat
constructor
A new instance of Flat.
Constructor Details
Instance Attribute Details
#data_files ⇒ Object (readonly)
Returns the value of attribute data_files.
23 24 25 |
# File 'lib/source_readers/flat.rb', line 23 def data_files @data_files end |
#libraries ⇒ Object (readonly)
Returns the value of attribute libraries.
23 24 25 |
# File 'lib/source_readers/flat.rb', line 23 def libraries @libraries end |
#metadata ⇒ Object (readonly)
Returns the value of attribute metadata.
23 24 25 |
# File 'lib/source_readers/flat.rb', line 23 def @metadata end |
#tests ⇒ Object (readonly)
Returns the value of attribute tests.
23 24 25 |
# File 'lib/source_readers/flat.rb', line 23 def tests @tests end |
Class Method Details
.resolve(target) ⇒ Object
13 14 15 16 17 18 19 20 21 |
# File 'lib/source_readers/flat.rb', line 13 def self.resolve(target) # TODO: eventually remove the metadata.rb exception here # when we have fully phased out metadata.rb in 1.0 files = target.files.find_all { |x| x.end_with?('.rb') && !x.include?('/') && x != 'metadata.rb' } return nil if files.empty? new(target, files) end |