KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > tonbeller > wcf > table > TableModelChangeEvent


1 /*
2  * ====================================================================
3  * This software is subject to the terms of the Common Public License
4  * Agreement, available at the following URL:
5  * http://www.opensource.org/licenses/cpl.html .
6  * Copyright (C) 2003-2004 TONBELLER AG.
7  * All Rights Reserved.
8  * You must accept the terms of that agreement to use this software.
9  * ====================================================================
10  *
11  *
12  */

13 package com.tonbeller.wcf.table;
14
15 import java.util.EventObject JavaDoc;
16
17 /**
18  * informs listeners about changes in the table model.
19  * <code>identityChanged == false</code> means a soft change,
20  * e.g. swapping rows - all caches will marked dirty, sorting and paging
21  * will be initialized again. <code>identityChanged == true</code> means
22  * that the identity of some rows or cells has changed, or the number
23  * of columns. If true, the table component resets everything including
24  * the selection.
25  *
26  * @author av
27  */

28
29 public class TableModelChangeEvent extends EventObject JavaDoc {
30   boolean identityChanged;
31   
32   public TableModelChangeEvent(TableModel source, boolean identityChanged) {
33     super(source);
34     this.identityChanged = identityChanged;
35   }
36   
37   public TableModel getTableModel() {
38     return (TableModel)getSource();
39   }
40
41   public boolean isIdentityChanged() {
42     return identityChanged;
43   }
44
45 }
46
Popular Tags