public class OrderedHashSet<T> extends LinkedHashSet<T>
| 限定符和类型 | 字段和说明 |
|---|---|
protected ArrayList<T> |
elements
Track the elements as they are added to the set
|
| 构造器和说明 |
|---|
OrderedHashSet() |
| 限定符和类型 | 方法和说明 |
|---|---|
boolean |
add(T value)
Add a value to list; keep in hashtable for consistency also;
Key is object itself.
|
void |
clear() |
Object |
clone() |
List<T> |
elements()
Return the List holding list of table elements.
|
boolean |
equals(Object o) |
T |
get(int i) |
int |
hashCode() |
Iterator<T> |
iterator() |
boolean |
remove(int i) |
boolean |
remove(Object o) |
T |
set(int i,
T value)
Replace an existing value with a new value; updates the element
list and the hash table, but not the key as that has not changed.
|
Object[] |
toArray() |
String |
toString() |
spliteratorremoveAlladdAll, containsAll, retainAll, toArrayparallelStream, removeIf, streampublic T get(int i)
public T set(int i, T value)
public boolean remove(int i)
public boolean add(T value)
public boolean remove(Object o)
public void clear()
public int hashCode()
hashCode 在接口中 Collection<T>hashCode 在接口中 Set<T>hashCode 在类中 AbstractSet<T>public boolean equals(Object o)
equals 在接口中 Collection<T>equals 在接口中 Set<T>equals 在类中 AbstractSet<T>public List<T> elements()
public Object[] toArray()
toArray 在接口中 Collection<T>toArray 在接口中 Set<T>toArray 在类中 AbstractCollection<T>public String toString()
toString 在类中 AbstractCollection<T>Copyright © 1992–2022 Daniel Sun. All rights reserved.