Class Intersection<A>
- java.lang.Object
-
- com.jnape.palatable.lambda.semigroup.builtin.Intersection<A>
-
- Type Parameters:
A- theIterableelement type
- All Implemented Interfaces:
Fn1<java.lang.Iterable<A>,Fn1<java.lang.Iterable<A>,java.lang.Iterable<A>>>,Fn2<java.lang.Iterable<A>,java.lang.Iterable<A>,java.lang.Iterable<A>>,Applicative<Fn1<java.lang.Iterable<A>,java.lang.Iterable<A>>,Fn1<java.lang.Iterable<A>,?>>,Cartesian<java.lang.Iterable<A>,Fn1<java.lang.Iterable<A>,java.lang.Iterable<A>>,Fn1<?,?>>,Cocartesian<java.lang.Iterable<A>,Fn1<java.lang.Iterable<A>,java.lang.Iterable<A>>,Fn1<?,?>>,Contravariant<java.lang.Iterable<A>,Profunctor<?,Fn1<java.lang.Iterable<A>,java.lang.Iterable<A>>,Fn1<?,?>>>,Functor<Fn1<java.lang.Iterable<A>,java.lang.Iterable<A>>,Fn1<java.lang.Iterable<A>,?>>,Profunctor<java.lang.Iterable<A>,Fn1<java.lang.Iterable<A>,java.lang.Iterable<A>>,Fn1<?,?>>,Monad<Fn1<java.lang.Iterable<A>,java.lang.Iterable<A>>,Fn1<java.lang.Iterable<A>,?>>,MonadReader<java.lang.Iterable<A>,Fn1<java.lang.Iterable<A>,java.lang.Iterable<A>>,Fn1<java.lang.Iterable<A>,?>>,MonadRec<Fn1<java.lang.Iterable<A>,java.lang.Iterable<A>>,Fn1<java.lang.Iterable<A>,?>>,MonadWriter<java.lang.Iterable<A>,Fn1<java.lang.Iterable<A>,java.lang.Iterable<A>>,Fn1<java.lang.Iterable<A>,?>>,Semigroup<java.lang.Iterable<A>>
public final class Intersection<A> extends java.lang.Object implements Semigroup<java.lang.Iterable<A>>
Given twoIterablesxsandys, return thedistinctelements ofxsthat are also inysin order of their unique occurrence inxs.
-
-
Field Summary
Fields Modifier and Type Field Description private static Intersection<?>INSTANCE
-
Constructor Summary
Constructors Modifier Constructor Description privateIntersection()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Iterable<A>checkedApply(java.lang.Iterable<A> xs, java.lang.Iterable<A> ys)static <A> Intersection<A>intersection()static <A> Fn1<java.lang.Iterable<A>,java.lang.Iterable<A>>intersection(java.lang.Iterable<A> xs)static <A> java.lang.Iterable<A>intersection(java.lang.Iterable<A> xs, java.lang.Iterable<A> ys)-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.jnape.palatable.lambda.functions.Fn1
andThen, carry, cartesian, censor, choose, cocartesian, diMap, diMapR, discardL, flatMap, fmap, lazyZip, listens, local, pure, self, thunk, toFunction, trampolineM, zip, zip
-
-
-
-
Field Detail
-
INSTANCE
private static final Intersection<?> INSTANCE
-
-
Method Detail
-
checkedApply
public java.lang.Iterable<A> checkedApply(java.lang.Iterable<A> xs, java.lang.Iterable<A> ys)
- Specified by:
checkedApplyin interfaceFn2<java.lang.Iterable<A>,java.lang.Iterable<A>,java.lang.Iterable<A>>
-
intersection
public static <A> Intersection<A> intersection()
-
intersection
public static <A> Fn1<java.lang.Iterable<A>,java.lang.Iterable<A>> intersection(java.lang.Iterable<A> xs)
-
intersection
public static <A> java.lang.Iterable<A> intersection(java.lang.Iterable<A> xs, java.lang.Iterable<A> ys)
-
-