public class TableFocusTracker extends Object implements Closeable
| Modifier and Type | Field and Description |
|---|---|
protected xyz.cofe.collection.Func4<Object,Integer,Integer,Integer,Integer> |
cellChanged |
protected xyz.cofe.collection.Func2<Object,Integer,Integer> |
cellReader |
protected boolean |
compareColumn |
protected boolean |
compareObject |
protected boolean |
compareRow |
protected xyz.cofe.collection.Func2<Boolean,Object,Object> |
equalsComparator |
protected xyz.cofe.collection.Func6<Object,Integer,Integer,Object,Integer,Integer,Object> |
itemChanged |
protected int |
lastFocusedColumn |
protected Object |
lastFocusedItem |
protected int |
lastFocusedRow |
protected xyz.cofe.common.CloseableSet |
listeners |
protected xyz.cofe.collection.Func2<Object,Integer,Integer> |
rowChanged |
protected JTable |
table |
protected WeakReference<JTable> |
tableRef |
protected Timer |
timer |
| Constructor and Description |
|---|
TableFocusTracker(JTable table,
int delay,
boolean weak) |
| Modifier and Type | Method and Description |
|---|---|
TableFocusTracker |
cellChanged(xyz.cofe.collection.Func4<Object,Integer,Integer,Integer,Integer> cellChanged) |
protected void |
cellChanged(Object lastItm,
int lastRow,
int lastCol,
Object currentItem,
int currentRow,
int currentCol) |
TableFocusTracker |
cellReader(xyz.cofe.collection.Func2<Object,Integer,Integer> cellReader) |
protected void |
changed(Object lastItm,
int lastRow,
int lastCol,
Object currentItem,
int currentRow,
int currentCol) |
protected void |
checkChanges() |
void |
close() |
TableFocusTracker |
compareColumn(boolean compareColumn) |
protected boolean |
compareEquals(Object i0,
Object i1) |
TableFocusTracker |
compareObject(boolean compareObject) |
TableFocusTracker |
compareRow(boolean compareRow) |
TableFocusTracker |
equalsComparator(xyz.cofe.collection.Func2<Boolean,Object,Object> equalsComparator) |
protected void |
finalize() |
xyz.cofe.collection.Func4<Object,Integer,Integer,Integer,Integer> |
getCellChanged() |
xyz.cofe.collection.Func2<Object,Integer,Integer> |
getCellReader() |
xyz.cofe.collection.Func2<Boolean,Object,Object> |
getEqualsComparator() |
int |
getFocusedColumn() |
int |
getFocusedRow() |
Object |
getItem(int row,
int col) |
xyz.cofe.collection.Func6<Object,Integer,Integer,Object,Integer,Integer,Object> |
getItemChanged() |
int |
getLastFocusedColumn() |
Object |
getLastFocusedItem() |
int |
getLastFocusedRow() |
xyz.cofe.collection.Func2<Object,Integer,Integer> |
getRowChanged() |
JTable |
getTable() |
Timer |
getTimer() |
boolean |
isCompareColumn() |
boolean |
isCompareObject() |
boolean |
isCompareRow() |
boolean |
isRunning() |
TableFocusTracker |
itemChanged(xyz.cofe.collection.Func6<Object,Integer,Integer,Object,Integer,Integer,Object> rowChanged)
Вызывает указанную функцию при изменении фокуса
|
protected void |
itemChanged(Object lastItm,
int lastRow,
int lastCol,
Object currentItem,
int currentRow,
int currentCol) |
TableFocusTracker |
itemChanged(xyz.cofe.common.Reciver<Object> rowChanged) |
protected void |
onTableHide() |
protected void |
onTableShow() |
TableFocusTracker |
rowChanged(xyz.cofe.collection.Func2<Object,Integer,Integer> rowChanged) |
protected void |
rowChanged(Object lastItm,
int lastRow,
int lastCol,
Object currentItem,
int currentRow,
int currentCol) |
void |
setCellChanged(xyz.cofe.collection.Func4<Object,Integer,Integer,Integer,Integer> cellChanged) |
void |
setCellReader(xyz.cofe.collection.Func2<Object,Integer,Integer> cellReader) |
void |
setCompareColumn(boolean compareColumn) |
void |
setCompareObject(boolean compareObject) |
void |
setCompareRow(boolean compareRow) |
void |
setEqualsComparator(xyz.cofe.collection.Func2<Boolean,Object,Object> equalsComparator) |
void |
setItemChanged(xyz.cofe.collection.Func6<Object,Integer,Integer,Object,Integer,Integer,Object> rowChanged) |
void |
setRowChanged(xyz.cofe.collection.Func2<Object,Integer,Integer> rowChanged) |
TableFocusTracker |
start() |
TableFocusTracker |
stop() |
TableFocusTracker |
timerDelay(int delay) |
static TableFocusTracker |
tracking(JTable tbl,
boolean weak) |
protected xyz.cofe.common.CloseableSet listeners
protected Timer timer
protected JTable table
protected WeakReference<JTable> tableRef
protected boolean compareRow
protected boolean compareColumn
protected boolean compareObject
protected Object lastFocusedItem
protected int lastFocusedRow
protected int lastFocusedColumn
protected volatile xyz.cofe.collection.Func4<Object,Integer,Integer,Integer,Integer> cellChanged
public TableFocusTracker(JTable table, int delay, boolean weak)
protected void onTableHide()
protected void onTableShow()
protected void finalize()
throws Throwable
public void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableIOExceptionpublic static TableFocusTracker tracking(JTable tbl, boolean weak)
public TableFocusTracker timerDelay(int delay)
public TableFocusTracker start()
public TableFocusTracker stop()
public boolean isRunning()
public Timer getTimer()
public JTable getTable()
public int getFocusedRow()
public int getFocusedColumn()
public void setCellReader(xyz.cofe.collection.Func2<Object,Integer,Integer> cellReader)
public TableFocusTracker cellReader(xyz.cofe.collection.Func2<Object,Integer,Integer> cellReader)
public Object getItem(int row, int col)
public boolean isCompareRow()
public void setCompareRow(boolean compareRow)
public TableFocusTracker compareRow(boolean compareRow)
public boolean isCompareColumn()
public void setCompareColumn(boolean compareColumn)
public TableFocusTracker compareColumn(boolean compareColumn)
public boolean isCompareObject()
public void setCompareObject(boolean compareObject)
public TableFocusTracker compareObject(boolean compareObject)
public void setEqualsComparator(xyz.cofe.collection.Func2<Boolean,Object,Object> equalsComparator)
public TableFocusTracker equalsComparator(xyz.cofe.collection.Func2<Boolean,Object,Object> equalsComparator)
public Object getLastFocusedItem()
public int getLastFocusedRow()
public int getLastFocusedColumn()
protected void checkChanges()
protected void changed(Object lastItm, int lastRow, int lastCol, Object currentItem, int currentRow, int currentCol)
public void setRowChanged(xyz.cofe.collection.Func2<Object,Integer,Integer> rowChanged)
public TableFocusTracker rowChanged(xyz.cofe.collection.Func2<Object,Integer,Integer> rowChanged)
protected void rowChanged(Object lastItm, int lastRow, int lastCol, Object currentItem, int currentRow, int currentCol)
public xyz.cofe.collection.Func4<Object,Integer,Integer,Integer,Integer> getCellChanged()
public void setCellChanged(xyz.cofe.collection.Func4<Object,Integer,Integer,Integer,Integer> cellChanged)
public TableFocusTracker cellChanged(xyz.cofe.collection.Func4<Object,Integer,Integer,Integer,Integer> cellChanged)
protected void cellChanged(Object lastItm, int lastRow, int lastCol, Object currentItem, int currentRow, int currentCol)
public xyz.cofe.collection.Func6<Object,Integer,Integer,Object,Integer,Integer,Object> getItemChanged()
public void setItemChanged(xyz.cofe.collection.Func6<Object,Integer,Integer,Object,Integer,Integer,Object> rowChanged)
public TableFocusTracker itemChanged(xyz.cofe.collection.Func6<Object,Integer,Integer,Object,Integer,Integer,Object> rowChanged)
rowChanged - fn( last, current ) => dummypublic TableFocusTracker itemChanged(xyz.cofe.common.Reciver<Object> rowChanged)
Copyright © 2018. All rights reserved.