aboutsummaryrefslogblamecommitdiffstats
path: root/activerecord/lib/active_record/connection_adapters/type/float.rb
blob: 51cfa5d86a22d7548a9c62db33ee646d46347fd5 (plain) (tree)
1
2
3
4
5
6
7
8
9



                                   

                       


                
 



                 




                             



         
module ActiveRecord
  module ConnectionAdapters
    module Type
      class Float < Value # :nodoc:
        include Numeric

        def type
          :float
        end

        def klass
          ::Float
        end

        private

        def cast_value(value)
          value.to_f
        end
      end
    end
  end
end