![JAR search and dependency download from the Maven repository](/logo.png)
com.github.dakusui.lisj.pred.Or Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jcunit Show documentation
Show all versions of jcunit Show documentation
Automated combinatorial testing framework on top of JUnit
package com.github.dakusui.lisj.pred;
import com.github.dakusui.jcunit.exceptions.JCUnitException;
import com.github.dakusui.lisj.CUT;
import com.github.dakusui.lisj.Context;
import com.github.dakusui.lisj.FormResult;
public class Or extends LogicalPredicate {
/**
* Serial version UID.
*/
private static final long serialVersionUID = 6418029016956795143L;
@Override
protected FormResult evaluateEach(Context context,
Object currentParam, FormResult lastResult) throws JCUnitException, CUT {
FormResult ret = super.evaluateEach(context, currentParam, lastResult);
if (ret.value() instanceof Boolean) {
if (((Boolean)ret.value())) cut(true);
} else {
throw new IllegalArgumentException(msgReturnedTypeMismatch(Boolean.class, ret.value()));
}
return ret;
}
@Override
protected boolean initialValue() {
return false;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy