Class: DohDb::SmartRow

Inherits:
AbstractSmartRow show all
Defined in:
lib/dohmysql/smart_row.rb

Instance Attribute Summary

Attributes inherited from AbstractSmartRow

#changed_keys, #table

Attributes inherited from AbstractRow

#keys, #values

Instance Method Summary collapse

Methods inherited from AbstractSmartRow

#clear_changed_keys, #db_update, #delete, #guess_missing_get, #guess_missing_set, #initialize_copy, #merge!, #method_missing, #primary_key, #set

Methods inherited from AbstractRow

#at, #each_pair, #empty_field?, #get, #inspect, #key?, #size, #to_a, #to_h

Constructor Details

#initialize(*args) ⇒ SmartRow

Returns a new instance of SmartRow.



86
87
88
89
90
91
92
# File 'lib/dohmysql/smart_row.rb', line 86

def initialize(*args)
  parsed_args = parse_initialize_args(*args)
  if parsed_args.size == 3
    @table = parsed_args.pop
  end
  super(*parsed_args)
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class DohDb::AbstractSmartRow