Index: app/sql/statement.cc |
=================================================================== |
--- app/sql/statement.cc (revision 26110) |
+++ app/sql/statement.cc (working copy) |
@@ -170,7 +170,7 @@ |
return result; |
} |
-int Statement::ColumnByteLength(int col) { |
+int Statement::ColumnByteLength(int col) const { |
if (!is_valid()) { |
NOTREACHED(); |
return 0; |
@@ -178,7 +178,7 @@ |
return sqlite3_column_bytes(ref_->stmt(), col); |
} |
-const void* Statement::ColumnBlob(int col) { |
+const void* Statement::ColumnBlob(int col) const { |
if (!is_valid()) { |
NOTREACHED(); |
return NULL; |
@@ -187,7 +187,7 @@ |
return sqlite3_column_blob(ref_->stmt(), col); |
} |
-void Statement::ColumnBlobAsVector(int col, std::vector<char>* val) { |
+void Statement::ColumnBlobAsVector(int col, std::vector<char>* val) const { |
val->clear(); |
if (!is_valid()) { |
NOTREACHED(); |
@@ -202,6 +202,12 @@ |
} |
} |
+void Statement::ColumnBlobAsVector( |
+ int col, |
+ std::vector<unsigned char>* val) const { |
+ ColumnBlobAsVector(col, reinterpret_cast< std::vector<char>* >(val)); |
+} |
+ |
int Statement::CheckError(int err) { |
succeeded_ = (err == SQLITE_OK || err == SQLITE_ROW || err == SQLITE_DONE); |