← 返回首页
Iterable (Java SE 26 & JDK 26)
JavaScript is disabled on your browser.
Contents  
  1. Description
  2. Method Summary
  3. Method Details
    1. iterator()
    2. forEach(Consumer)
    3. spliterator()
Hide sidebar  Show sidebar

Interface Iterable<T>

Type Parameters: T - the type of elements returned by the iterator All Known Subinterfaces: BeanContext, BeanContextServices, BlockingDeque<E>, BlockingQueue<E>, ClassModel, ClassReader, CodeAttribute, CodeModel, Collection<E>, CompoundElement<E>, ConstantPool, ConstantPoolBuilder, Deque<E>, DirectoryStream<T>, EventSet, FieldModel, List<E>, MethodModel, NavigableSet<E>, NodeSetData<T>, Path, Queue<E>, SecureDirectoryStream<T>, SequencedCollection<E>, SequencedSet<E>, Set<E>, SortedSet<E>, TransferQueue<E>, XPathNodes All Known Implementing Classes: AbstractCollection, AbstractList, AbstractQueue, AbstractSequentialList, AbstractSet, ArrayBlockingQueue, ArrayDeque, ArrayList, AttributeList, BatchUpdateException, BeanContextServicesSupport, BeanContextSupport, ConcurrentHashMap.KeySetView, ConcurrentLinkedDeque, ConcurrentLinkedQueue, ConcurrentSkipListSet, CopyOnWriteArrayList, CopyOnWriteArraySet, DataTruncation, DelayQueue, DocTreePath, EnumSet, HashSet, JobStateReasons, LinkedBlockingDeque, LinkedBlockingQueue, LinkedHashSet, LinkedList, LinkedTransferQueue, PriorityBlockingQueue, PriorityQueue, RoleList, RoleUnresolvedList, RowSetWarning, SerialException, ServiceLoader, SQLClientInfoException, SQLDataException, SQLException, SQLFeatureNotSupportedException, SQLIntegrityConstraintViolationException, SQLInvalidAuthorizationSpecException, SQLNonTransientConnectionException, SQLNonTransientException, SQLRecoverableException, SQLSyntaxErrorException, SQLTimeoutException, SQLTransactionRollbackException, SQLTransientConnectionException, SQLTransientException, SQLWarning, Stack, SyncFactoryException, SynchronousQueue, SyncProviderException, TreePath, TreeSet, Vector
public interface Iterable<T>
Implementing this interface allows an object to be the target of the enhanced for statement (sometimes called the "for-each loop" statement).
See Java Language Specification: 14.14.2 The enhanced for statement
Since: 1.5

Scripting on this page tracks web page traffic, but does not change the content in any way.