add a few classes and methods to the classpath

Add java.lang.CharSequence, java.util.AbstractSet,
java.util.AbstractCollection, Collections.unmodifiableSet,
 System.getProperty(String,String), etc.
This commit is contained in:
Zsombor
2008-07-03 09:16:32 -06:00
committed by Joel Dice
parent 107ac01304
commit e3fd0d9c7d
10 changed files with 226 additions and 14 deletions

View File

@ -10,7 +10,7 @@
package java.util;
public class TreeSet<T> implements Collection<T> {
public class TreeSet<T> extends AbstractSet<T> implements Collection<T> {
private PersistentSet<Cell<T>> set;
private int size;
@ -41,12 +41,6 @@ public class TreeSet<T> implements Collection<T> {
return false;
}
public boolean addAll(Collection<? extends T> collection) {
boolean change = false;
for (T t: collection) if (add(t)) change = true;
return change;
}
// Used by hashMaps for replacement
public void addAndReplace(T value) {
PersistentSet.Path<Cell<T>> p = set.find(new Cell(value, null));
@ -75,10 +69,6 @@ public class TreeSet<T> implements Collection<T> {
}
}
public <T> T[] toArray(T[] array) {
return Collections.toArray(this, array);
}
public int size() {
return size;
}