This commit is contained in:
thosakwe 2017-06-16 22:00:24 -04:00
parent e3ccf98b69
commit 328224fc10

View file

@ -161,6 +161,7 @@ tend to be snake_cased. This is not a problem, because we can define an alias
for a field. for a field.
```dart ```dart
@serializable
abstract class _Spy extends Model { abstract class _Spy extends Model {
/// Will show up as 'agency_id' in serialized JSON. /// Will show up as 'agency_id' in serialized JSON.
/// ///
@ -178,6 +179,7 @@ In pratice, there may keys that you want to exclude from JSON.
To accomplish this, simply annotate them with `@exclude`: To accomplish this, simply annotate them with `@exclude`:
```dart ```dart
@serializable
abstract class _Whisper extends Model { abstract class _Whisper extends Model {
/// Will never be serialized to JSON /// Will never be serialized to JSON
@exclude @exclude