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.
| 20 21 22 | # File 'lib/source_readers/flat.rb', line 20 def data_files @data_files end | 
#libraries ⇒ Object (readonly)
Returns the value of attribute libraries.
| 20 21 22 | # File 'lib/source_readers/flat.rb', line 20 def libraries @libraries end | 
#metadata ⇒ Object (readonly)
Returns the value of attribute metadata.
| 20 21 22 | # File 'lib/source_readers/flat.rb', line 20 def @metadata end | 
#tests ⇒ Object (readonly)
Returns the value of attribute tests.
| 20 21 22 | # File 'lib/source_readers/flat.rb', line 20 def tests @tests end | 
Class Method Details
.resolve(target) ⇒ Object
| 9 10 11 12 13 14 15 16 17 18 | # File 'lib/source_readers/flat.rb', line 9 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 do |x| x.end_with?(".rb") && !x.include?("/") && x != "metadata.rb" end return nil if files.empty? new(target, files) end |