copyWith method

ForeignKeyOption copyWith({
  1. ObjectName? foreignTable,
  2. List<Ident>? referredColumns,
  3. Option<ReferentialAction>? onDelete,
  4. Option<ReferentialAction>? onUpdate,
})

Returns a new instance by overriding the values passed as arguments

Implementation

ForeignKeyOption copyWith({
  ObjectName? foreignTable,
  List<Ident>? referredColumns,
  Option<ReferentialAction>? onDelete,
  Option<ReferentialAction>? onUpdate,
}) =>
    ForeignKeyOption(
        foreignTable: foreignTable ?? this.foreignTable,
        referredColumns: referredColumns ?? this.referredColumns,
        onDelete: onDelete != null ? onDelete.value : this.onDelete,
        onUpdate: onUpdate != null ? onUpdate.value : this.onUpdate);