Tweaked code indentation and formatting to match existing style

This commit is contained in:
Eric Scharff
2008-07-03 10:49:08 -06:00
parent befdfa4e9e
commit bba4f75c2f
7 changed files with 115 additions and 156 deletions

View File

@ -189,51 +189,51 @@ public class Collections {
}
static class UnmodifiableSet<T> implements Set<T> {
Set<T> inner;
Set<T> inner;
UnmodifiableSet(Set<T> inner) {
this.inner = inner;
}
public boolean add(T element) {
throw new UnsupportedOperationException("not supported");
}
UnmodifiableSet(Set<T> inner) {
this.inner = inner;
}
public boolean add(T element) {
throw new UnsupportedOperationException("not supported");
}
public boolean addAll(Collection<? extends T> collection) {
throw new UnsupportedOperationException("not supported");
}
public boolean addAll(Collection<? extends T> collection) {
throw new UnsupportedOperationException("not supported");
}
public void clear() {
throw new UnsupportedOperationException("not supported");
}
public void clear() {
throw new UnsupportedOperationException("not supported");
}
public boolean contains(T element) {
return inner.contains(element);
}
public boolean contains(T element) {
return inner.contains(element);
}
public boolean isEmpty() {
return inner.isEmpty();
}
public boolean isEmpty() {
return inner.isEmpty();
}
public Iterator<T> iterator() {
return inner.iterator();
}
public Iterator<T> iterator() {
return inner.iterator();
}
public boolean remove(T element) {
throw new UnsupportedOperationException("not supported");
}
public boolean remove(T element) {
throw new UnsupportedOperationException("not supported");
}
public int size() {
return inner.size();
}
public int size() {
return inner.size();
}
public <S> S[] toArray(S[] array) {
return inner.toArray(array);
}
public <S> S[] toArray(S[] array) {
return inner.toArray(array);
}
}
public static <T> Set<T> unmodifiableSet(Set<T> hs) {
return new UnmodifiableSet<T>(hs);
}
public static <T> Set<T> unmodifiableSet(Set<T> hs) {
return new UnmodifiableSet<T>(hs);
}
}