Sha256: 47341cb20b2a3c692b7d559dbebaee8da102cee80bbdd77d3a0dda863cef5dde
Contents?: true
Size: 632 Bytes
Versions: 1
Compression:
Stored size: 632 Bytes
Contents
require 'active_record/connection_adapters/mysql2_adapter' module ActiveRecord module ConnectionAdapters class Mysql2Adapter < AbstractMysqlAdapter class Version include Comparable def initialize(version_string) @version = version_string.split('.').map(&:to_i) end def <=>(version_string) @version <=> version_string.split('.').map(&:to_i) end def [](index) @version[index] end end def version @version ||= Version.new(@connection.server_info[:version].match(/^\d+\.\d+\.\d+/)[0]) end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
activerecord-mysql-awesome-0.0.9 | lib/activerecord-mysql-awesome/active_record/connection_adapters/mysql2_adapter.rb |