class Sequel::JDBC::TypeConvertor
Constants
- BASIC_MAP
- MAP
Public Instance Methods
RubyBigDecimal(r, i)
click to toggle source
# File lib/sequel/adapters/jdbc.rb 81 def RubyBigDecimal(r, i) 82 if v = r.getBigDecimal(i) 83 ::Kernel::BigDecimal(v.to_string) 84 end 85 end
RubyBlob(r, i)
click to toggle source
# File lib/sequel/adapters/jdbc.rb 86 def RubyBlob(r, i) 87 if v = r.getBytes(i) 88 Sequel::SQL::Blob.new(String.from_java_bytes(v)) 89 end 90 end
RubyClob(r, i)
click to toggle source
# File lib/sequel/adapters/jdbc.rb 91 def RubyClob(r, i) 92 if v = r.getClob(i) 93 v.getSubString(1, v.length) 94 end 95 end
RubyDate(r, i)
click to toggle source
# File lib/sequel/adapters/jdbc.rb 71 def RubyDate(r, i) 72 if v = r.getDate(i) 73 Date.civil(v.getYear + 1900, v.getMonth + 1, v.getDate) 74 end 75 end
RubyTime(r, i)
click to toggle source
# File lib/sequel/adapters/jdbc.rb 66 def RubyTime(r, i) 67 if v = r.getTime(i) 68 Sequel.string_to_time("#{v.to_string}.#{sprintf('%03i', v.getTime.divmod(1000).last)}") 69 end 70 end
RubyTimestamp(r, i)
click to toggle source
# File lib/sequel/adapters/jdbc.rb 76 def RubyTimestamp(r, i) 77 if v = r.getTimestamp(i) 78 Sequel.database_to_application_timestamp([v.getYear + 1900, v.getMonth + 1, v.getDate, v.getHours, v.getMinutes, v.getSeconds, v.getNanos]) 79 end 80 end