KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > jface > internal > databinding > provisional > observable > list > IObservableList


1 /*******************************************************************************
2  * Copyright (c) 2006 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials
4  * are made available under the terms of the Eclipse Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/epl-v10.html
7  *
8  * Contributors:
9  * IBM Corporation - initial API and implementation
10  ******************************************************************************/

11
12 package org.eclipse.jface.internal.databinding.provisional.observable.list;
13
14 import java.util.Collection JavaDoc;
15 import java.util.Iterator JavaDoc;
16 import java.util.List JavaDoc;
17 import java.util.ListIterator JavaDoc;
18
19 import org.eclipse.jface.internal.databinding.provisional.observable.IObservableCollection;
20
21 /**
22  * A list whose changes can be tracked by change listeners.
23  *
24  * @since 1.0
25  */

26 public interface IObservableList extends List JavaDoc, IObservableCollection {
27     
28     /**
29      * Adds the given list change listener to the list of list change listeners.
30      * @param listener
31      */

32     public void addListChangeListener(IListChangeListener listener);
33     
34     /**
35      * Removes the given list change listener from the list of list change listeners.
36      * Has no effect if the given listener is not registered as a list change listener.
37      *
38      * @param listener
39      */

40     public void removeListChangeListener(IListChangeListener listener);
41
42     /**
43      * @TrackedGetter
44      */

45     public int size();
46
47     /**
48      * @TrackedGetter
49      */

50     public boolean isEmpty();
51
52     /**
53      * @TrackedGetter
54      */

55     public boolean contains(Object JavaDoc o);
56
57     /**
58      * @TrackedGetter
59      */

60     public Iterator JavaDoc iterator();
61
62     /**
63      * @TrackedGetter
64      */

65     public Object JavaDoc[] toArray();
66
67     /**
68      * @TrackedGetter
69      */

70     public Object JavaDoc[] toArray(Object JavaDoc a[]);
71
72     /**
73      * @TrackedGetter because of the returned boolean
74      */

75     public boolean add(Object JavaDoc o);
76
77     /**
78      * @TrackedGetter
79      */

80     public boolean remove(Object JavaDoc o);
81
82     /**
83      * @TrackedGetter
84      */

85     public boolean containsAll(Collection JavaDoc c);
86
87     /**
88      * @TrackedGetter
89      */

90     public boolean addAll(Collection JavaDoc c);
91
92     /**
93      * @TrackedGetter
94      */

95     public boolean addAll(int index, Collection JavaDoc c);
96
97     /**
98      * @TrackedGetter
99      */

100     public boolean removeAll(Collection JavaDoc c);
101
102     /**
103      * @TrackedGetter
104      */

105     public boolean retainAll(Collection JavaDoc c);
106
107     /**
108      * @TrackedGetter
109      */

110     public boolean equals(Object JavaDoc o);
111
112     /**
113      * @TrackedGetter
114      */

115     public int hashCode();
116
117     /**
118      * @TrackedGetter
119      */

120     public Object JavaDoc get(int index);
121
122     /**
123      * @TrackedGetter because of the returned object
124      */

125     public Object JavaDoc set(int index, Object JavaDoc element);
126
127     /**
128      * @TrackedGetter
129      */

130     public Object JavaDoc remove(int index);
131
132     /**
133      * @TrackedGetter
134      */

135     public int indexOf(Object JavaDoc o);
136
137     /**
138      * @TrackedGetter
139      */

140     public int lastIndexOf(Object JavaDoc o);
141
142     /**
143      * @TrackedGetter
144      */

145     public ListIterator JavaDoc listIterator();
146
147     /**
148      * @TrackedGetter
149      */

150     public ListIterator JavaDoc listIterator(int index);
151
152     /**
153      * @TrackedGetter
154      */

155     public List JavaDoc subList(int fromIndex, int toIndex);
156
157     /**
158      * @return the type of the elements
159      */

160     Object JavaDoc getElementType();
161 }
162
Popular Tags