style fixes

This commit is contained in:
Guenter Obiltschnig 2016-09-01 11:51:16 +02:00
parent 3feaaa6987
commit fd9ca0a9b6
2 changed files with 8 additions and 10 deletions

View File

@ -57,13 +57,12 @@ public:
static const int OPERATION_UPDATE;
static void addColumnType(std::string sqliteType, MetaColumn::ColumnDataType pocoType);
/// Adds or replaces the mapping for SQLite column type \p sqliteType
/// to a Poco type \p pocoType
/// Adds or replaces the mapping for SQLite column type sqliteType
/// to a Poco type pocoType.
///
/// \p sqliteType is a case-insensitive desription of the column type with
/// any value \p pocoType value but MetaColumn::FDT_UNKNOWN. A
/// Poco::Data::NotSupportedException is thrown if \p pocoType is invalid.
/// sqliteType is a case-insensitive desription of the column type with
/// any value pocoType value but MetaColumn::FDT_UNKNOWN.
/// A Poco::Data::NotSupportedException is thrown if pocoType is invalid.
static sqlite3* dbHandle(const Session& session);
/// Returns native DB handle.

View File

@ -66,6 +66,7 @@ Utility::Utility()
initializeDefaultTypes();
}
void Utility::initializeDefaultTypes()
{
if (_types.empty())
@ -167,12 +168,10 @@ MetaColumn::ColumnDataType Utility::getColumnType(sqlite3_stmt* pStmt, std::size
sqliteType = sqliteType.substr(0, sqliteType.find_first_of(" ("));
TypeMap::const_iterator it = _types.find(Poco::trimInPlace(sqliteType));
if (_types.end() == it) {
if (_types.end() == it)
return MetaColumn::FDT_BLOB;
}
else {
else
return it->second;
}
}