use of suite.primitive.adt.pair.ChrDblPair in project suite by stupidsing.
the class ChrDblFunUtil method mapChrDbl.
public static ChrDblSource mapChrDbl(ChrDbl_Chr kf0, ChrDbl_Dbl vf0, ChrDblSource source2) {
ChrDbl_Chr kf1 = kf0.rethrow();
ChrDbl_Dbl vf1 = vf0.rethrow();
ChrDblPair pair1 = ChrDblPair.of((char) 0, (double) 0);
return pair -> {
boolean b = source2.source2(pair1);
if (b)
pair.update(kf1.apply(pair1.t0, pair1.t1), vf1.apply(pair1.t0, pair1.t1));
return b;
};
}
use of suite.primitive.adt.pair.ChrDblPair in project suite by stupidsing.
the class ChrDblFunUtil method isAny.
public static <V> boolean isAny(ChrDblPredicate pred0, ChrDblSource source2) {
ChrDblPredicate pred1 = pred0.rethrow();
ChrDblPair pair = ChrDblPair.of((char) 0, (double) 0);
while (source2.source2(pair)) if (pred1.test(pair.t0, pair.t1))
return true;
return false;
}
use of suite.primitive.adt.pair.ChrDblPair in project suite by stupidsing.
the class ChrDblFunUtil method map.
public static <T> Source<T> map(ChrDbl_Obj<T> fun0, ChrDblSource source2) {
ChrDbl_Obj<T> fun1 = fun0.rethrow();
ChrDblPair pair = ChrDblPair.of((char) 0, (double) 0);
return () -> source2.source2(pair) ? fun1.apply(pair.t0, pair.t1) : null;
}
Aggregations