java.util
Class HashSet
java.lang.Object
java.util.AbstractCollection
java.util.AbstractSet
java.util.HashSet
- All Implemented Interfaces:
- Cloneable, Collection, Serializable, Set
- Direct Known Subclasses:
- JTypeDeclaration.PleomorphSet, LinkedHashSet
- public class HashSet
- extends AbstractSet
- implements Set, Cloneable, Serializable
PRESENT
private static final Object PRESENT
map
private transient HashMap map
serialVersionUID
static final long serialVersionUID
HashSet
public HashSet()
HashSet
public HashSet(int)
HashSet
public HashSet(int,
float)
HashSet
HashSet(int,
float,
boolean)
HashSet
public HashSet(Collection)
size
public int size()
- Specified by:
size in interface Set
clear
public void clear()
- Specified by:
clear in interface Set- Overrides:
clear in class AbstractCollection
isEmpty
public boolean isEmpty()
- Specified by:
isEmpty in interface Set- Overrides:
isEmpty in class AbstractCollection
readObject
private void readObject(ObjectInputStream)
throws IOException,
ClassNotFoundException
- Throws:
IOException
ClassNotFoundException
writeObject
private void writeObject(ObjectOutputStream)
throws IOException
- Throws:
IOException
clone
public Object clone()
- Overrides:
clone in class Object
add
public boolean add(Object)
- Specified by:
add in interface Set- Overrides:
add in class AbstractCollection
contains
public boolean contains(Object)
- Specified by:
contains in interface Set- Overrides:
contains in class AbstractCollection
remove
public boolean remove(Object)
- Specified by:
remove in interface Set- Overrides:
remove in class AbstractCollection
iterator
public Iterator iterator()
- Specified by:
iterator in interface Set
JML is Copyright (C) 1998-2002 by Iowa State University and is distributed under the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This release depends on code from the MultiJava project and is based in part on the Kopi project Copyright (C) 1990-99 DMS Decision Management Systems Ges.m.b.H.