java.util
Class HashSet
java.lang.Object
|
+--java.util.AbstractCollection
|
+--java.util.AbstractSet
|
+--java.util.HashSet
- All Implemented Interfaces:
- Collection, Set
- public class HashSet
- extends AbstractSet
Methods inherited from class java.lang.Object |
finalize, getClass, notify, notifyAll, wait, wait, wait |
HashSet
public HashSet()
HashSet
public HashSet(Collection c)
HashSet
public HashSet(int initialCapacity,
float loadFactor)
HashSet
public HashSet(int initialCapacity)
iterator
public Iterator iterator()
- Specified by:
iterator
in interface Collection
- Specified by:
iterator
in class AbstractCollection
size
public int size()
- Specified by:
size
in interface Collection
- Specified by:
size
in class AbstractCollection
contains
public boolean contains(java.lang.Object o)
- Specified by:
contains
in interface Collection
- Overrides:
contains
in class AbstractCollection
add
public boolean add(java.lang.Object o)
- Specified by:
add
in interface Collection
- Overrides:
add
in class AbstractCollection
remove
public boolean remove(java.lang.Object o)
- Specified by:
remove
in interface Collection
- Overrides:
remove
in class AbstractCollection
clear
public void clear()
- Specified by:
clear
in interface Collection
- Overrides:
clear
in class AbstractCollection
clone
public java.lang.Object clone()
- Overrides:
clone
in class java.lang.Object