toJson method
Implementation
@override
String? toJson(TextCapitalization? object) {
if (object == null) return null;
switch (object) {
case TextCapitalization.characters:
return 'characters';
case TextCapitalization.none:
return 'none';
case TextCapitalization.sentences:
return 'sentences';
case TextCapitalization.words:
return 'words';
}
}