copyWith method
A copy with the given properties replaced; everything else, unknown keys included, is kept.
Implementation
Annotations copyWith({
List<Role>? audience,
num? priority,
String? lastModified,
}) =>
Annotations.fromJson({
...toJson(),
if (audience != null) 'audience': $encode(audience),
if (priority != null) 'priority': $encode(priority),
if (lastModified != null) 'lastModified': $encode(lastModified),
});