Interface CellChangeIf<T>

One changed cell: row, column, old and new value – the unit of a change set (GeModelChangeEvent.changes, TableApi.getPendingChanges). With old and new value it is enough for undo and redo.

Example

const listener = new EventAdapter();
listener.onModelChanged = (evt: GeModelChangeEvent) => {
for (const change of evt.changes ?? []) {
console.log(change.property, change.oldValue, "→", change.newValue, change.row);
}
};

Since

1.1.96

Type Parameters

  • T = any

Hierarchy

  • CellChangeIf

Properties

columnIndex: number

Model index of the column when the change was reported, -1 if the column no longer exists.

error?: string

Batch edit: the message of ColumnDefIf.validate if the new value is invalid.

newValue: unknown

The new value (after the column's editInputPipe).

oldValue: unknown

The value before the change (batch edit: before the first change of the cell).

property: string

The property of the column ("#3" for a column without property).

row: T

The row object (tree: the data of the TreeRow); undefined for own area models without row objects.

rowIndex: number

Display index of the row when the change was reported, -1 if a filter hides the row.