Iterable Interface
Package: java.util
The Iterable
interface must be implemented by any class that can be used by Java’s enhanced for
statement (commonly called “foreach”).
This interface defines a single method named iterator
, which returns an object that implements the Iterator
interface. For more information, see Iterator Interface.
Method
Method |
Explanation |
|
Returns an |