KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > java > util > Set


1 /*
2  * Copyright 2006 Google Inc.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License"); you may not
5  * use this file except in compliance with the License. You may obtain a copy of
6  * the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
12  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
13  * License for the specific language governing permissions and limitations under
14  * the License.
15  */

16 package java.util;
17
18 /**
19  * Represents a set of unique objects.
20  */

21 public interface Set extends Collection JavaDoc {
22
23   boolean add(Object JavaDoc o);
24
25   boolean addAll(Collection JavaDoc c);
26
27   void clear();
28
29   boolean contains(Object JavaDoc o);
30
31   boolean containsAll(Collection JavaDoc c);
32
33   boolean equals(Object JavaDoc o);
34
35   int hashCode();
36
37   boolean isEmpty();
38
39   Iterator JavaDoc iterator();
40
41   boolean remove(Object JavaDoc o);
42
43   boolean removeAll(Collection JavaDoc c);
44
45   boolean retainAll(Collection JavaDoc c);
46
47   int size();
48
49   Object JavaDoc[] toArray();
50
51 }
52
Popular Tags