Sha256: 48891a64fb71b68803a72119c44c5bf0e0ea023a7644792811eaa281cde8052f
Contents?: true
Size: 517 Bytes
Versions: 22
Compression:
Stored size: 517 Bytes
Contents
module Acfs::Model module Attributes # @api public # # Float attribute type. Use it in your model as an attribute type: # # @example # class User # include Acfs::Model # attribute :name, :float # end # module Float # @api public # # Cast given object to float. # # @param [Object] obj Object to cast. # @return [Float] Casted object as float. # def self.cast(obj) obj.to_f end end end end
Version data entries
22 entries across 22 versions & 1 rubygems