Sha256: b1b31336796e5970bde6ccbdd15d586913fe88169cd1a8a2d919cbeb96d66870
Contents?: true
Size: 564 Bytes
Versions: 1
Compression:
Stored size: 564 Bytes
Contents
class Upsert class Row # @private class Mysql2_Client < Row attr_reader :original_setter_keys def initialize(controller, raw_selector, raw_setter) super @original_setter_keys = raw_setter.keys.map(&:to_s) end def quoted_setter_values @quoted_setter_values ||= setter.values.map(&:quoted_value) end def values_sql_bytesize @values_sql_bytesize ||= quoted_setter_values.inject(0) { |sum, quoted_value| sum + quoted_value.to_s.bytesize } + setter.length - 1 end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
upsert-1.0.2 | lib/upsert/row/Mysql2_Client.rb |