Examples of Quantifier


Examples of kodkod.ast.operator.Quantifier

  public final Formula visit(QuantifiedFormula qf) {
    Formula ret = lookup(qf);
    if (ret!=null) return ret;
   
    final Environment<Expression> oldRepEnv = repEnv; 
    final Quantifier quant = qf.quantifier();
    final Decls decls = qf.decls();
   
    if (skolemDepth>=0 && (negated && quant==ALL || !negated && quant==SOME)) { // skolemizable formula
      final List<Formula> rangeConstraints = new LinkedList<Formula>();
      final List<Formula> domConstraints = new LinkedList<Formula>();
View Full Code Here

Examples of kodkod.ast.operator.Quantifier

   */
  public final BooleanValue visit(QuantifiedFormula quantFormula) {
    BooleanValue ret = lookup(quantFormula);
    if (ret!=null) return ret;

    final Quantifier quantifier = quantFormula.quantifier();

    switch(quantifier) {
    case ALL    :
      final BooleanAccumulator and = BooleanAccumulator.treeGate(Operator.AND);
      all(quantFormula.decls(), quantFormula.formula(), 0, BooleanConstant.FALSE, and);
View Full Code Here

Examples of kodkod.ast.operator.Quantifier

  public final void visit(QuantifiedFormula qf) {
    if (visited(qf)) return;
   
    if (breakupQuantifiers) {
     
      final Quantifier quant = qf.quantifier();
     
      if ((!negated && quant==ALL) || (negated && quant==SOME)) { // may break down further
        final Map<Formula, Node> oldConjuncts = conjuncts;
        conjuncts = new LinkedHashMap<Formula, Node>();
        qf.formula().accept(this);
View Full Code Here

Examples of org.apache.vxquery.types.Quantifier

    private SequenceType sequenceType;

    public boolean sequenceTypeMatch(TaggedValuePointable tvp) {
        byte tag = tvp.getTag();
        Quantifier stq = sequenceType.getQuantifier();
        ItemType it = sequenceType.getItemType();
        if (tag == ValueTag.SEQUENCE_TAG) {
            tvp.getValue(seqp);
            Quantifier vq = getSequenceQuantifier(seqp);
            if (stq.isSubQuantifier(vq)) {
                if (it instanceof AnyItemType) {
                    return true;
                } else {
                    int n = seqp.getEntryCount();
View Full Code Here

Examples of org.apache.vxquery.types.Quantifier

        }
        return false;
    }

    public boolean matchesAllInstances(SequenceType testST) {
        Quantifier stq = sequenceType.getQuantifier();
        ItemType it = sequenceType.getItemType();
        if (stq.isSubQuantifier(testST.getQuantifier())) {
            if (it instanceof AnyItemType) {
                return true;
            } else if (it.isAtomicType() && testST.getItemType().isAtomicType()) {
                AtomicType ait = (AtomicType) it;
                AtomicType testIT = (AtomicType) testST.getItemType();
View Full Code Here

Examples of org.apache.vxquery.types.Quantifier

                if (sType.getItemType() == null) {
                    return SequenceType.create(AnyItemType.INSTANCE, Quantifier.QUANT_STAR);
                }

                TypeQuantifier tq = sType.getQuantifier();
                Quantifier q = Quantifier.QUANT_ONE;
                if (tq != null) {
                    switch (tq) {
                        case QUANT_QUESTION:
                            q = Quantifier.QUANT_QUESTION;
                            break;
View Full Code Here

Examples of org.apache.vxquery.types.Quantifier

                if (sType.getItemType() == null) {
                    return SequenceType.create(AnyItemType.INSTANCE, Quantifier.QUANT_STAR);
                }

                TypeQuantifier tq = sType.getQuantifier();
                Quantifier q = Quantifier.QUANT_ONE;
                if (tq != null) {
                    switch (tq) {
                        case QUANT_QUESTION:
                            q = Quantifier.QUANT_QUESTION;
                            break;
View Full Code Here

Examples of org.apache.vxquery.types.Quantifier

    private SequenceType sequenceType;

    public boolean sequenceTypeMatch(TaggedValuePointable tvp) {
        byte tag = tvp.getTag();
        Quantifier stq = sequenceType.getQuantifier();
        ItemType it = sequenceType.getItemType();
        if (tag == ValueTag.SEQUENCE_TAG) {
            tvp.getValue(seqp);
            Quantifier vq = getSequenceQuantifier(seqp);
            if (stq.isSubQuantifier(vq)) {
                if (it instanceof AnyItemType) {
                    return true;
                } else {
                    int n = seqp.getEntryCount();
View Full Code Here

Examples of org.apache.vxquery.types.Quantifier

                if (sType.getItemType() == null) {
                    return SequenceType.create(AnyItemType.INSTANCE, Quantifier.QUANT_STAR);
                }

                TypeQuantifier tq = sType.getQuantifier();
                Quantifier q = Quantifier.QUANT_ONE;
                if (tq != null) {
                    switch (tq) {
                        case QUANT_QUESTION:
                            q = Quantifier.QUANT_QUESTION;
                            break;
View Full Code Here

Examples of org.teiid.language.SubqueryComparison.Quantifier

                                  translatedExpressions,
                                  criteria.isNegated());
    }

    SubqueryComparison translate(SubqueryCompareCriteria criteria) {
        Quantifier quantifier = Quantifier.ALL;
        switch(criteria.getPredicateQuantifier()) {
            case SubqueryCompareCriteria.ALL:  
                quantifier = Quantifier.ALL;
                break;
            case SubqueryCompareCriteria.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.