copyWith method

ModelSchema copyWith({
  1. String? name,
  2. String? pluralName,
  3. List<AuthRule>? authRules,
  4. Map<String, ModelField>? fields,
  5. List<ModelIndex>? indexes,
})

Implementation

ModelSchema copyWith({
  String? name,
  String? pluralName,
  List<AuthRule>? authRules,
  Map<String, ModelField>? fields,
  List<ModelIndex>? indexes,
}) {
  return ModelSchema(
    name: name ?? this.name,
    pluralName: pluralName ?? this.pluralName,
    authRules: authRules ?? this.authRules,
    fields: fields ?? this.fields,
    indexes: indexes ?? this.indexes,
  );
}