Class: DatabaseHelper::SQLColumn
- Inherits:
- 
      Object
      
        - Object
- DatabaseHelper::SQLColumn
 
- Defined in:
- lib/utils/database_helpers.rb
Instance Method Summary collapse
- 
  
    
      #initialize(row, name)  ⇒ SQLColumn 
    
    
  
  
  
    constructor
  
  
  
  
  
  
  
    A new instance of SQLColumn. 
- #to_s ⇒ Object
- #value ⇒ Object
Constructor Details
#initialize(row, name) ⇒ SQLColumn
Returns a new instance of SQLColumn.
| 7 8 9 10 | # File 'lib/utils/database_helpers.rb', line 7 def initialize(row, name) @row = row @name = name end | 
Instance Method Details
#to_s ⇒ Object
| 16 17 18 | # File 'lib/utils/database_helpers.rb', line 16 def to_s 'SQL Column' end | 
#value ⇒ Object
| 12 13 14 | # File 'lib/utils/database_helpers.rb', line 12 def value @row.nil? ? '' : @row[@name.downcase] end |