requireMapToSql method
Map a non-null value from an object in Dart into something that will be understood by the database.
Implementation
@override
int requireMapToSql(T value) {
// In Dart 2.14: Cast to Enum instead of dynamic. Also add Enum as an upper
// bound for T.
return (value as dynamic).index as int;
}