setFieldValue method
Set a field's value by fieldId
. Primitive types must be "boxed" in the
appropriate object wrapper type.
Implementation
setFieldValue(int fieldID, Object? value) {
switch (fieldID) {
case INDEX_ID:
if (value == null) {
unsetIndex_id();
} else {
this.index_id = value as int;
}
break;
case FILTER:
if (value == null) {
unsetFilter();
} else {
this.filter = value as Int8List?;
}
break;
case COLUMN_HINTS:
if (value == null) {
unsetColumn_hints();
} else {
this.column_hints = value as List<IndexColumnHint>?;
}
break;
default:
throw new ArgumentError("Field $fieldID doesn't exist!");
}
}