mirror of
https://github.com/corda/corda.git
synced 2025-06-13 04:38:19 +00:00
Added methods isEmpty(), putAll(), toArray() to interfaces List and Map
This commit is contained in:
@ -11,6 +11,13 @@ public class Vector<T> implements List<T> {
|
||||
this(0);
|
||||
}
|
||||
|
||||
public Vector(List<T> list) {
|
||||
this(list.size());
|
||||
for (T o : list) {
|
||||
add(o);
|
||||
}
|
||||
}
|
||||
|
||||
public synchronized int size() {
|
||||
return list.size();
|
||||
}
|
||||
@ -39,6 +46,14 @@ public class Vector<T> implements List<T> {
|
||||
return list.remove(index);
|
||||
}
|
||||
|
||||
public synchronized boolean isEmpty() {
|
||||
return list.isEmpty();
|
||||
}
|
||||
|
||||
public synchronized <S> S[] toArray(S[] a) {
|
||||
return list.toArray(a);
|
||||
}
|
||||
|
||||
public T removeElementAt(int index) {
|
||||
return remove(index);
|
||||
}
|
||||
|
Reference in New Issue
Block a user