org.expasy.jpl.commons.collection
Interface ExtraIterable<T>

Type Parameters:
T - the type of element in iteration.
All Superinterfaces:
Iterable<T>
All Known Subinterfaces:
IndexIterable, SequenceIterable<T>
All Known Implementing Classes:
AbstractSequencePositioner, MotifMatcher

public interface ExtraIterable<T>
extends Iterable<T>

ExtraIterable inherits from Iterable and adds the functionality of returning its next elements into a list.

The Iterable JPL object and the way iteration will be done are tightly coupled in this interface : the implementer will have to code an Iterator inner class that extends AbstractIterator and override hasNext() and next() methods.

Version:
1.0
Author:
nikitin

Nested Class Summary
static class ExtraIterable.AbstractExtraIterator<T>
          Abstract inner class with default implementation of nextToList methods.
 
Method Summary
 ExtraIterable.AbstractExtraIterator<T> iterator()
          Returns a JPL iterator over a set of elements of type T.
 

Method Detail

iterator

ExtraIterable.AbstractExtraIterator<T> iterator()
Returns a JPL iterator over a set of elements of type T.

Specified by:
iterator in interface Iterable<T>
Returns:
a JPL iterator.


Copyright (c) 2012 Swiss Institute of Bioinformatics. All rights reserved.