soot.util
Class ArraySet
java.lang.Object
java.util.AbstractCollection<E>
java.util.AbstractSet
soot.util.ArraySet
- All Implemented Interfaces:
- Iterable, Collection, Set
public class ArraySet
- extends AbstractSet
Provides an implementation of the Set object using java.util.Array
ArraySet
public ArraySet(int size)
ArraySet
public ArraySet()
ArraySet
public ArraySet(Object[] elements)
- Create a set which contains the given elements.
clear
public final void clear()
- Specified by:
clear
in interface Collection
- Specified by:
clear
in interface Set
- Overrides:
clear
in class AbstractCollection
contains
public final boolean contains(Object obj)
- Specified by:
contains
in interface Collection
- Specified by:
contains
in interface Set
- Overrides:
contains
in class AbstractCollection
addElement
public final boolean addElement(Object e)
- Add an element without checking whether it is already in the set.
It is up to the caller to guarantee that it isn't.
add
public final boolean add(Object e)
- Specified by:
add
in interface Collection
- Specified by:
add
in interface Set
- Overrides:
add
in class AbstractCollection
addAll
public final boolean addAll(Collection s)
- Specified by:
addAll
in interface Collection
- Specified by:
addAll
in interface Set
- Overrides:
addAll
in class AbstractCollection
size
public final int size()
- Specified by:
size
in interface Collection
- Specified by:
size
in interface Set
- Specified by:
size
in class AbstractCollection
iterator
public final Iterator iterator()
- Specified by:
iterator
in interface Iterable
- Specified by:
iterator
in interface Collection
- Specified by:
iterator
in interface Set
- Specified by:
iterator
in class AbstractCollection
toArray
public final Object[] toArray()
- Specified by:
toArray
in interface Collection
- Specified by:
toArray
in interface Set
- Overrides:
toArray
in class AbstractCollection
toArray
public final Object[] toArray(Object[] array)
- Specified by:
toArray
in interface Collection
- Specified by:
toArray
in interface Set
- Overrides:
toArray
in class AbstractCollection
getUnderlyingArray
public final Object[] getUnderlyingArray()