如何將以下1.5+結構重寫爲1.4?將Java 1.5+支持到1.4
final class FooList<T> extends AbstractList<T> implements ...
{
private T[] tab;
...
}
public ListIterator<T> listIterator() {...}
public int bar(int x, Collection<? extends T> c) {...}
for (Foo f : s.baz(x)) {...}
for (Map.Entry<Object, Object> e : p.entrySet()) {...}
'final class FooList extends AbstractList ... {private Object [] tab;}'? – user1367401
3. - 索引不等於for-each。必須使用迭代器。 –