本文整理汇总了Java中ap.parser.IPlus类的典型用法代码示例。如果您正苦于以下问题:Java IPlus类的具体用法?Java IPlus怎么用?Java IPlus使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
IPlus类属于ap.parser包,在下文中一共展示了IPlus类的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getName
import ap.parser.IPlus; //导入依赖的package包/类
private String getName(IExpression input) {
if (input instanceof IAtom || input instanceof IConstant) {
return input.toString();
} else if (input instanceof IBinFormula) {
return ((IBinFormula) input).j().toString();
} else if (input instanceof IFormulaITE || input instanceof ITermITE) {
// in princess ite representation is the complete formula which we do not want here
return "ite";
} else if (input instanceof IIntFormula) {
return ((IIntFormula) input).rel().toString();
} else if (input instanceof INot) {
// in princess not representation is the complete formula which we do not want here
return "not";
} else if (input instanceof IFunApp) {
return ((IFunApp) input).fun().name();
} else if (input instanceof IPlus) {
// in princess plus representation is the complete formula which we do not want here
return "+";
} else if (input instanceof ITimes) {
// in princess times representation is the complete formula which we do not want here
return "*";
} else if (input instanceof IEpsilon) {
// in princess epsilon representation is the complete formula which we do not want here
return "eps";
} else {
throw new AssertionError("Unhandled type " + input.getClass());
}
}
示例2: mkPlus
import ap.parser.IPlus; //导入依赖的package包/类
public ProverExpr mkPlus(ProverExpr left, ProverExpr right) {
return new TermExpr(new IPlus(((TermExpr) left).term,
((TermExpr) right).term), getIntType());
}
示例3: mkMinus
import ap.parser.IPlus; //导入依赖的package包/类
public ProverExpr mkMinus(ProverExpr left, ProverExpr right) {
return new TermExpr(new IPlus(((TermExpr) left).term,
((TermExpr) right).term.unary_$minus()), getIntType());
}