Class: ActiveRecord::ConnectionAdapters::PostgreSQL::OID::Decimal
- Defined in:
- lib/arjdbc/postgresql/base/oid.rb
Instance Method Summary collapse
Methods inherited from Type
Instance Method Details
#infinity(options = {}) ⇒ Object
285 286 287 |
# File 'lib/arjdbc/postgresql/base/oid.rb', line 285 def infinity( = {}) BigDecimal.new("Infinity") * ([:negative] ? -1 : 1) end |
#type ⇒ Object
277 |
# File 'lib/arjdbc/postgresql/base/oid.rb', line 277 def type; :decimal end |
#type_cast(value) ⇒ Object
279 280 281 282 283 |
# File 'lib/arjdbc/postgresql/base/oid.rb', line 279 def type_cast(value) return if value.nil? ConnectionAdapters::Column.value_to_decimal value end |