nameFormatter property

NameFormatter nameFormatter
final

Determine the format for a field, none by default

Example:

class Model {
  String myField;
}

@GenSerializer(fieldFormat: FieldFormat.snakeCase)
class ModelSerializer extends Serializer ... {}

final map = { 'my_field': 'foo' };
final model = serializer.fromMap(map);
print(model.myField); // print 'foo'

Implementation

final NameFormatter nameFormatter;