Why does the Iterator interface not extend Iterable?
The iterator() method could simply return this.
Is it on purpose or just an oversight of Java's designers?
It would be convenient to be able to use a for-each loop with iterators like this:
for(Object o : someContainer.listSomeObjects()) {
....
}
where listSomeObjects() returns an iterator.