src/org/kocakosm/pitaya/collection/Iterators.java
public static <E> Iterator<E> limit(Iterator<? extends E> iterator,
		int limit)
	{
		return new LimitIterator<E>(iterator, limit);
	}
public static <E> Iterator<E> limit(Iterator<? extends E> iterator,
		int limit)
	{
		return new LimitIterator<E>(iterator, limit);
	}
public static < E > Iterator < E > limit ( Iterator < ? extends E > iterator , int limit ) { return new LimitIterator < E > ( iterator , limit ) ; }
Creates an {@code Iterator} returning only the first {@code limit}
elements of the given {@code Iterator}. The source {@code Iterator}
is not polled until necessary. The returned {@code Iterator} supports
{@link Iterator#remove()} if the source {@code Iterator} supports it.

@param <E> the type of the returned {@code Iterator}'s elements.
@param iterator the {@code Iterator} to limit.
@param limit the number of elements in the returned {@code Iterator}.

@return the limited {@code Iterator}.

@throws NullPointerException if {@code iterator} is {@code null}.
@throws IllegalArgumentException if ({@code limit} is negative.
Creates an { @code Iterator } returning only the first { @code limit } elements of the given { @code Iterator } . The source { @code Iterator } is not polled until necessary . The returned { @code Iterator } supports { @link Iterator#remove () } if the source { @code Iterator } supports it .