Parent

SQLite3::Value

Attributes

handle[R]

Public Class Methods

new( db, handle ) click to toggle source
    # File lib/sqlite3/value.rb, line 8
 8:     def initialize( db, handle )
 9:       @driver = db.driver
10:       @handle = handle
11:     end

Public Instance Methods

length( utf16=false ) click to toggle source
    # File lib/sqlite3/value.rb, line 21
21:     def length( utf16=false )
22:       if utf16
23:         @driver.value_bytes16( @handle )
24:       else
25:         @driver.value_bytes( @handle )
26:       end
27:     end
null?() click to toggle source
    # File lib/sqlite3/value.rb, line 13
13:     def null?
14:       type == :null
15:     end
to_blob() click to toggle source
    # File lib/sqlite3/value.rb, line 17
17:     def to_blob
18:       @driver.value_blob( @handle )
19:     end
to_f() click to toggle source
    # File lib/sqlite3/value.rb, line 29
29:     def to_f
30:       @driver.value_double( @handle )
31:     end
to_i() click to toggle source
    # File lib/sqlite3/value.rb, line 33
33:     def to_i
34:       @driver.value_int( @handle )
35:     end
to_int64() click to toggle source
    # File lib/sqlite3/value.rb, line 37
37:     def to_int64
38:       @driver.value_int64( @handle )
39:     end
to_s( utf16=false ) click to toggle source
    # File lib/sqlite3/value.rb, line 41
41:     def to_s( utf16=false )
42:       @driver.value_text( @handle, utf16 )
43:     end
type() click to toggle source
    # File lib/sqlite3/value.rb, line 45
45:     def type
46:       case @driver.value_type( @handle )
47:         when Constants::ColumnType::INTEGER then :int
48:         when Constants::ColumnType::FLOAT   then :float
49:         when Constants::ColumnType::TEXT    then :text
50:         when Constants::ColumnType::BLOB    then :blob
51:         when Constants::ColumnType::NULL    then :null
52:       end
53:     end

Disabled; run with --debug to generate this.

[Validate]

Generated with the Darkfish Rdoc Generator 1.1.6.