Package kodkod.ast

Examples of kodkod.ast.Expression.apply()


        final Expression skolemExpr = skolemExpr(skolemDecl, skolem);
       
        final Multiplicity mult = decl.multiplicity();
        rangeConstraints.add(source(skolemExpr.in(skolemDecl.expression()), decl));
        if (mult!=Multiplicity.SET) {
          rangeConstraints.add(source(skolemExpr.apply(mult), decl));
        }

        if (!nonSkolems.isEmpty())
          domConstraints.add(source(domainConstraint(skolemDecl, skolem), decl));
       
View Full Code Here


    Expression ret = lookup(unaryExpr);
    if (ret!=null) return ret;

    final Expression child = unaryExpr.expression().accept(this);
    ret = (child==unaryExpr.expression()) ?
        unaryExpr : child.apply(unaryExpr.op());
    return cache(unaryExpr,ret);
  }
 
  /**
   * Calls lookup(comprehension) and returns the cached value, if any. 
View Full Code Here

    public IntExpression visit(ExprToIntCast intExpr) {
    IntExpression ret = lookup(intExpr);
    if (ret!=null) return ret;
 
    final Expression expr = intExpr.expression().accept(this);
    ret = expr==intExpr.expression() ? intExpr : expr.apply(intExpr.op());
    return cache(intExpr, ret);
    }
    /**
   * Calls lookup(intExpr) and returns the cached value, if any. 
View Full Code Here

    Formula ret = lookup(multFormula);
    if (ret!=null) return ret;
   
    final Expression expression = multFormula.expression().accept(this);
    ret = (expression==multFormula.expression()) ?
        multFormula : expression.apply(multFormula.multiplicity());
    return cache(multFormula,ret);
  }
 
  /**
   * Calls lookup(pred) and returns the cached value, if any. 
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.