T - item typepublic interface ReorderableModel<T>
| Modifier and Type | Method and Description |
|---|---|
default boolean |
canMove(int delta,
java.util.function.IntSupplier rowCount,
int... rows)
Checks that a range of rows can be moved by a given number of positions.
|
default boolean |
canMoveDown(java.util.function.IntSupplier rowCount,
int... rows)
Checks that a range of rows can be moved down (by 1 position).
|
default boolean |
canMoveUp(java.util.function.IntSupplier rowCount,
int... rows)
Checks that a range of rows can be moved up (by 1 position).
|
default boolean |
doMove(int delta,
int... selectedRows)
Performs the move operation, without any check nor selection handling.
|
T |
getValue(int index)
Get object value at given index.
|
T |
setValue(int index,
T value)
Set object value at given index.
|
T getValue(int index)
index - indexT setValue(int index, T value)
index - indexvalue - new valuedefault boolean canMove(int delta, java.util.function.IntSupplier rowCount, int... rows)
delta - negative or positive deltarowCount - row count supplierrows - indexes of rows to movetrue if rows can be moveddefault boolean canMoveUp(java.util.function.IntSupplier rowCount, int... rows)
rowCount - row count supplierrows - indexes of rows to move uptrue if rows can be moved updefault boolean canMoveDown(java.util.function.IntSupplier rowCount, int... rows)
rowCount - row count supplierrows - indexes of rows to move downtrue if rows can be moved downdefault boolean doMove(int delta, int... selectedRows)
delta - negative or positive deltaselectedRows - rows to movetrue if rows have been moved