KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > javax > swing > MutableComboBoxModel


1 /*
2  * @(#)MutableComboBoxModel.java 1.12 03/12/19
3  *
4  * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
5  * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
6  */

7 package javax.swing;
8
9 /**
10  * A mutable version of <code>ComboBoxModel</code>.
11  *
12  * @version 1.12 12/19/03
13  * @author Tom Santos
14  */

15
16 public interface MutableComboBoxModel extends ComboBoxModel JavaDoc {
17
18     /**
19      * Adds an item at the end of the model. The implementation of this method
20      * should notify all registered <code>ListDataListener</code>s that the
21      * item has been added.
22      *
23      * @param obj the <code>Object</code> to be added
24      */

25     public void addElement( Object JavaDoc obj );
26
27     /**
28      * Removes an item from the model. The implementation of this method should
29      * should notify all registered <code>ListDataListener</code>s that the
30      * item has been removed.
31      *
32      * @param obj the <code>Object</code> to be removed
33      */

34     public void removeElement( Object JavaDoc obj );
35
36     /**
37      * Adds an item at a specific index. The implementation of this method
38      * should notify all registered <code>ListDataListener</code>s that the
39      * item has been added.
40      *
41      * @param obj the <code>Object</code> to be added
42      * @param index location to add the object
43      */

44     public void insertElementAt( Object JavaDoc obj, int index );
45
46     /**
47      * Removes an item at a specific index. The implementation of this method
48      * should notify all registered <code>ListDataListener</code>s that the
49      * item has been removed.
50      *
51      * @param index location of object to be removed
52      */

53     public void removeElementAt( int index );
54 }
55
56
57
Popular Tags