Examples of appendComparator()


Examples of ca.odell.glazedlists.swing.TableComparatorChooser.appendComparator()

        assertEquals(3, table.getColumnCount());


        // 2. wire up a TableComparatorChooser and make the third column sort
        TableComparatorChooser chooser = TableComparatorChooser.install(table, sorted, AbstractTableComparatorChooser.SINGLE_COLUMN);
        chooser.appendComparator(2, 0, false);

        // the TableComparatorChooser should install a PropertyChangeListener on the JTable
        assertEquals(initialNumPropertyChangeListenersOnJTable+1, table.getPropertyChangeListeners().length);
        // the TableComparatorChooser should install a TableModelListener on the EventTableModel
        assertEquals(2, firstModel.getTableModelListeners().length);
View Full Code Here

Examples of ca.odell.glazedlists.swing.TableComparatorChooser.appendComparator()

        assertTrue(chooser.getSortingColumns().isEmpty());
        assertEquals(2, firstModel.getTableModelListeners().length);


        // 4. reapply a sort to the JTable on the first column
        chooser.appendComparator(0, 0, false);
        assertEquals(1, chooser.getSortingColumns().size());


        // 5. set a new EventTableModel that only uses 2 columns
        secondModel = new EventTableModel<String>(sorted, new TestTableFormat(2));
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.