|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectca.odell.glazedlists.swing.JXTableSupport<E>
public class JXTableSupport<E>
JXTableSupport
integrates a JXTable
with Glazed Lists by
DefaultEventTableModel
as table modelDefaultEventSelectionModel
as table selection modelTableComparatorChooser
as sorting integration approachWarning: This class must be
mutated from the Swing Event Dispatch Thread. Failure to do so will result in
an IllegalStateException
thrown from any one of:
Method Summary | ||
---|---|---|
org.jdesktop.swingx.JXTable |
getTable()
|
|
TableComparatorChooser<E> |
getTableComparatorChooser()
|
|
TableFormat<? super E> |
getTableFormat()
|
|
AdvancedTableModel<E> |
getTableModel()
|
|
AdvancedListSelectionModel<E> |
getTableSelectionModel()
|
|
static
|
install(org.jdesktop.swingx.JXTable table,
EventList<E> eventList,
TableFormat<? super E> tableFormat,
SortedList<E> sortedList,
Object sortingStrategy)
Installs the Glazed Lists integration on the given table . |
|
boolean |
isInstalled()
|
|
void |
uninstall()
Uninstalls the GlazedLists integration and restores the state of JXTable as it was before the installation. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static <E> JXTableSupport<E> install(org.jdesktop.swingx.JXTable table, EventList<E> eventList, TableFormat<? super E> tableFormat, SortedList<E> sortedList, Object sortingStrategy)
table
.
First, the current state of the table is determined to be able to restore this state when the integration is uninstalled again. Then this method installs
DefaultEventTableModel
as table modelDefaultEventSelectionModel
as table selection modelTableComparatorChooser
as sorting integration approach
E
- element type of EventList
table
- the JXTable to integrate witheventList
- the EventList
acting as data source for the table model, must be *at least* as high as the sortedList
within the list pipeline.
It's possible to layer further transforms *above* the SortedList and pass one of those in as the data sourcetableFormat
- the TableFormat
to usesortedList
- the SortedList
to use with the TableComparatorChooser
sortingStrategy
- the SortingStrategy
to use with the
TableComparatorChooser
IllegalStateException
- if this method is called from any Thread
other than the Swing Event Dispatch ThreadTableComparatorChooser.install(javax.swing.JTable, SortedList, Object, TableFormat)
public org.jdesktop.swingx.JXTable getTable()
JXTable
or null
if JXTableSupport has already been uninstalledpublic AdvancedListSelectionModel<E> getTableSelectionModel()
AdvancedListSelectionModel
or null
if already uninstalledpublic AdvancedTableModel<E> getTableModel()
AdvancedTableModel
or null
if already uninstalledpublic TableFormat<? super E> getTableFormat()
TableFormat
or null
if already uninstalledpublic TableComparatorChooser<E> getTableComparatorChooser()
TableComparatorChooser
or null
if already uninstalledpublic void uninstall()
IllegalStateException
- if this method is called from any Thread
other than the Swing Event Dispatch Threadpublic boolean isInstalled()
JXTableSupport
instance is currently
installed and altering the behaviour of the JXTable; false if
it has been uninstall()
ed.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |