sdk/src/Platform/cordova/sqliteSerializer.js
function getSqliteType (columnType) {
    var sqliteType;

    switch (columnType) {
        case ColumnType.Object:
        case ColumnType.Array:
        case ColumnType.String:
        case ColumnType.Text:
            sqliteType = "TEXT";
            break;
        case ColumnType.Integer:
        case ColumnType.Int:
        case ColumnType.Boolean:
        case ColumnType.Bool:
        case ColumnType.Date:
            sqliteType = "INTEGER";
            break;
        case ColumnType.Real:
        case ColumnType.Float:
            sqliteType = "REAL";
            break;
        default:
            throw new Error('Column type ' + columnType + ' is not supported');
    }

    return sqliteType;
}
function getSqliteType (columnType) {
    var sqliteType;

    switch (columnType) {
        case ColumnType.Object:
        case ColumnType.Array:
        case ColumnType.String:
        case ColumnType.Text:
            sqliteType = "TEXT";
            break;
        case ColumnType.Integer:
        case ColumnType.Int:
        case ColumnType.Boolean:
        case ColumnType.Bool:
        case ColumnType.Date:
            sqliteType = "INTEGER";
            break;
        case ColumnType.Real:
        case ColumnType.Float:
            sqliteType = "REAL";
            break;
        default:
            throw new Error('Column type ' + columnType + ' is not supported');
    }

    return sqliteType;
}
function getSqliteType ( columnType ) { var sqliteType ; switch ( columnType ) { case ColumnType . Object : case ColumnType . Array : case ColumnType . String : case ColumnType . Text : sqliteType = "TEXT" ; break ; case ColumnType . Integer : case ColumnType . Int : case ColumnType . Boolean : case ColumnType . Bool : case ColumnType . Date : sqliteType = "INTEGER" ; break ; case ColumnType . Real : case ColumnType . Float : sqliteType = "REAL" ; break ; default : throw new Error ( 'Column type ' + columnType + ' is not supported' ) ; } return sqliteType ; }
Gets the SQLite type that matches the specified ColumnType.
@private
@param columnType - The type of values that will be stored in the SQLite table
@throw Will throw an error if columnType is not supported
Gets the SQLite type that matches the specified ColumnType .