| java.lang.Object net.sf.jga.algorithms.Unique
All known Subclasses: net.sf.jga.util.UniqueIterable, net.sf.jga.util.UniqueIterator,
Unique | public class Unique (Code) | | Algorithms that eliminate successive duplicate entries from a collection, iteration,
or iterable resource.
Copyright © 2006 David A. Hall
|
Inner Class :public static class UniqueIterable implements Iterable<T> | |
Inner Class :public static class UniqueIterator implements Iterator<T> | |
Method Summary | |
public static Iterable<T> | unique(T[] ts) Returns the elements of the array, skipping duplicate entries. | public static Iterable<T> | unique(T[] ts, Comparator<? super T> comp) Returns the elements of the array, skipping duplicate entries as determined by the given
comparator. | public static Iterable<T> | unique(T[] ts, BinaryFunctor<T, T, Boolean> eq) Returns the elements of the array, skipping duplicate entries as determined by the given
predicate. | public static Iterable<T> | unique(Iterable<? extends T> i) Returns the contents of the input, skipping duplicate entries. | public static Iterable<T> | unique(Iterable<? extends T> i, Comparator<? super T> comp) | public static Iterable<T> | unique(Iterable<? extends T> i, BinaryFunctor<T, T, Boolean> eq) | public static Iterator<T> | unique(Iterator<? extends T> iterator) Returns the contents of the iterator, skipping duplicate entries. | public static Iterator<T> | unique(Iterator<? extends T> iterator, Comparator<? super T> comp) Returns the contents of the iterator, skipping duplicate entries as determined by the given
comparator. | public static Iterator<T> | unique(Iterator<? extends T> iterator, BinaryFunctor<T, T, Boolean> eq) Returns the contents of the iterator, skipping duplicate entries as determined by the given
predicate. | public static TCollection | unique(Iterable<? extends T> lin, TCollection cout) Appends the contents of the input (skipping duplicate entries) to the output. | public static TCollection | unique(Iterable<? extends T> lin, Comparator<? super T> comp, TCollection cout) Appends the contents of the input (skipping duplicate entries as determined by the given
comparator) to the output. | public static TCollection | unique(Iterable<? extends T> lin, BinaryFunctor<T, T, Boolean> eq, TCollection cout) Appends the contents of the input (skipping duplicate entries as determined by the given
predicate) to the output. |
unique | public static Iterable<T> unique(T[] ts)(Code) | | Returns the elements of the array, skipping duplicate entries. This version uses T.equals()
to test for equality.
|
unique | public static Iterable<T> unique(T[] ts, Comparator<? super T> comp)(Code) | | Returns the elements of the array, skipping duplicate entries as determined by the given
comparator.
|
unique | public static Iterable<T> unique(T[] ts, BinaryFunctor<T, T, Boolean> eq)(Code) | | Returns the elements of the array, skipping duplicate entries as determined by the given
predicate. The predicate should return true when the adjacent items are the same.
|
unique | public static Iterable<T> unique(Iterable<? extends T> i)(Code) | | Returns the contents of the input, skipping duplicate entries. This version uses T.equals()
to test for equality.
|
unique | public static Iterator<T> unique(Iterator<? extends T> iterator)(Code) | | Returns the contents of the iterator, skipping duplicate entries. This version uses
T.equals() to test for equality.
|
unique | public static Iterator<T> unique(Iterator<? extends T> iterator, Comparator<? super T> comp)(Code) | | Returns the contents of the iterator, skipping duplicate entries as determined by the given
comparator.
|
unique | public static Iterator<T> unique(Iterator<? extends T> iterator, BinaryFunctor<T, T, Boolean> eq)(Code) | | Returns the contents of the iterator, skipping duplicate entries as determined by the given
predicate. The predicate should return true when the adjacent items are the same.
|
unique | public static TCollection unique(Iterable<? extends T> lin, TCollection cout)(Code) | | Appends the contents of the input (skipping duplicate entries) to the output. This version
uses T.equals() to test for equality.
|
unique | public static TCollection unique(Iterable<? extends T> lin, Comparator<? super T> comp, TCollection cout)(Code) | | Appends the contents of the input (skipping duplicate entries as determined by the given
comparator) to the output.
|
unique | public static TCollection unique(Iterable<? extends T> lin, BinaryFunctor<T, T, Boolean> eq, TCollection cout)(Code) | | Appends the contents of the input (skipping duplicate entries as determined by the given
predicate) to the output.
|
|
|