public class IteratorLikeIterable
implements java.lang.Iterable<java.lang.Object>, java.io.Closeable
This is a class that makes it easier to iterate over "iterator-like" objects as defined
in the ECMAScript spec. The caller is responsible for retrieving an object that implements
the "iterator" pattern. This class will follow that pattern and throw appropriate
The pattern that the target class should follow is:
* It should have a function property called "next"
* The property should return an object with a boolean value called "done".
* If "done" is true, then the returned object should also contain a "value" property.
* If it has a function property called "return" then it will be called
when the caller is done iterating.