| 
 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnet.sf.jga.algorithms.Unique.UniqueIterable<T>
public static class Unique.UniqueIterable<T>
Produces iterators that will not return the same element twice in succession.
Copyright © 2005 David A. Hall
| Constructor Summary | |
|---|---|
| Unique.UniqueIterable(java.lang.Iterable<? extends T> base)Builds a UniqueIterable for the given resource. | |
| Unique.UniqueIterable(java.lang.Iterable<? extends T> base,
                      BinaryFunctor<T,T,java.lang.Boolean> pred)Builds a UniqueIterable for the given base iterator that uses the given predicate to compare successive elements. | |
| Unique.UniqueIterable(java.lang.Iterable<? extends T> base,
                      java.util.Comparator<? super T> comp)Builds a UniqueIterable for the given base iterator, that uses the given Comparator | |
| Method Summary | |
|---|---|
|  java.util.Iterator<T> | iterator() | 
| Methods inherited from class java.lang.Object | 
|---|
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Constructor Detail | 
|---|
public Unique.UniqueIterable(java.lang.Iterable<? extends T> base)
java.lang.IllegalArgumentException - if the base iterable is null
public Unique.UniqueIterable(java.lang.Iterable<? extends T> base,
                             java.util.Comparator<? super T> comp)
java.lang.IllegalArgumentException - if either argument is null
public Unique.UniqueIterable(java.lang.Iterable<? extends T> base,
                             BinaryFunctor<T,T,java.lang.Boolean> pred)
java.lang.IllegalArgumentException - if the base iterable is null| Method Detail | 
|---|
public java.util.Iterator<T> iterator()
iterator in interface java.lang.Iterable<T>| 
 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||