com.github.basking2.sdsai.itrex.packages.BooleanPackage Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of sdsai-itrex Show documentation
Show all versions of sdsai-itrex Show documentation
An S-Expression inspiried library focused on iterators.
package com.github.basking2.sdsai.itrex.packages;
import com.github.basking2.sdsai.itrex.functions.FunctionInterface;
import com.github.basking2.sdsai.itrex.functions.bool.AndFunction;
import com.github.basking2.sdsai.itrex.functions.bool.CompareFunction;
import com.github.basking2.sdsai.itrex.functions.bool.NotFunction;
import com.github.basking2.sdsai.itrex.functions.bool.OrFunction;
/**
* Common functions that return booleans. Comparisons and logical, such as and, or etc.
*/
public class BooleanPackage {
public static final FunctionInterface and = new AndFunction();
public static final FunctionInterface or = new OrFunction();
public static final FunctionInterface not = new NotFunction();
public static final FunctionInterface eq = new CompareFunction(CompareFunction.OP.EQ);
public static final FunctionInterface gt = new CompareFunction(CompareFunction.OP.GT);
public static final FunctionInterface gte = new CompareFunction(CompareFunction.OP.GTE);
public static final FunctionInterface lt = new CompareFunction(CompareFunction.OP.LT);
public static final FunctionInterface lte = new CompareFunction(CompareFunction.OP.LTE);
public static final FunctionInterface t = (x,y) -> true;
public static final FunctionInterface f = (x,y) -> false;
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy