Method: Libsql::TypeMap#result_value_of

Defined in:
lib/libsql/type_map.rb

#result_value_of(delcared_type, value) ⇒ Object

:call-seq:

map.result_value_of( declared_type, value ) -> String

result_value_of is called during the result processing of column values to convert an SQLite database value into the appropriate Ruby class.

declared_type is the string from the original CREATE TABLE statment from which the column value originates. It may also be nil if the origin column cannot be determined.

value is the SQLite value from the column as either a Ruby String, Integer, Float or Libsql::Blob.

result_value should return the value that is to be put into the result set for the query. It may do nothing, or it may do massive amounts of conversion.

Raises:

  • (NotImplementedError)


43
44
45
# File 'lib/libsql/type_map.rb', line 43

def result_value_of( delcared_type, value )
  raise NotImplementedError, "result_value_of has not been implemented"
end