hiddenSerializableField method
Fields with !persist or scope ModelFieldScopeDefinition.none are hidden from the wire protocol but stored in the database. On the client, implicit one-to-many child keys are hidden.
Implementation
bool hiddenSerializableField(bool serverCode) {
if (serverCode) {
return shouldPersist && scope == ModelFieldScopeDefinition.none;
}
if (!shouldPersist || scope != ModelFieldScopeDefinition.none) {
return false;
}
final relation = this.relation;
return relation is ForeignRelationDefinition &&
relation.containerField == null;
}