Get this entry as Blob

If the Sqlite type of this entry is not a blob, it will be CAST to text. If null, returns a NULL pointer.

require: self.statement.is_open

Property definitions

sqlite3 $ StatementEntry :: to_blob
	# Get this entry as `Blob`
	#
	# If the Sqlite type of this entry is not a blob, it will be `CAST` to text.
	# If null, returns a NULL pointer.
	#
	# require: `self.statement.is_open`
	fun to_blob: Blob
	do
		assert statement_closed: statement.is_open

		# By spec, we must get the pointer before the byte count
		var pointer = statement.native_statement.column_blob(index)
		var length = statement.native_statement.column_bytes(index)

		return new Blob(pointer, length)
	end
lib/sqlite3/sqlite3.nit:258,2--273,4