map method
override
Maps the given row returned by the database into the fitting data class.
Implementation
@override
BackgroundRow map(Map<String, dynamic> data, {String? tablePrefix}) {
final effectivePrefix = tablePrefix != null ? '$tablePrefix.' : '';
return BackgroundRow(
userId: attachedDatabase.typeMapping.read(
DriftSqlType.string,
data['${effectivePrefix}user_id'],
)!,
data: attachedDatabase.typeMapping.read(
DriftSqlType.blob,
data['${effectivePrefix}data'],
)!,
);
}