- Type Parameters:
F - 源元素类型
T - 目标元素类型
- All Implemented Interfaces:
Iterator<T>
- Since:
- Java 17+
- Author:
- Kimi Liu
-
Constructor Summary
Constructors
-
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
TransIterator
public TransIterator(Iterator<? extends F> backingIterator,
Function<? super F,? extends T> func)
构造
- Parameters:
backingIterator - 源Iterator
func - 转换函数
-
Method Details
-
hasNext
public final boolean hasNext()
- Specified by:
hasNext in interface Iterator<F>
-
-
remove
public final void remove()
- Specified by:
remove in interface Iterator<F>