Examples of EmptySet


Examples of org.openrdf.query.algebra.EmptySet

      super.meet(join);

      for (TupleExpr arg : join.getArgs()) {
        if (arg instanceof EmptySet) {
          // Any join with an empty set always result in an empty set
          join.replaceWith(new EmptySet());
          return;
        }

        // singletons can be safely removed from a join, but be careful not
        // to create an empty join
View Full Code Here

Examples of org.openrdf.query.algebra.EmptySet

          union.removeArg(arg);
        }
      }

      if (union.getNumberOfArguments() == 0) {
        union.replaceWith(new EmptySet());
      }
      else if (union.getNumberOfArguments() == 1) {
        union.replaceWith(union.getArg(0));
      }
      else {
View Full Code Here

Examples of org.openrdf.query.algebra.EmptySet

      }
      else if (rightArg instanceof EmptySet) {
        difference.replaceWith(leftArg);
      }
      else if (leftArg instanceof SingletonSet && rightArg instanceof SingletonSet) {
        difference.replaceWith(new EmptySet());
      }
    }
View Full Code Here

Examples of org.openrdf.query.algebra.EmptySet

        result = new Distinct(result);
      }
    }
    else {
      // Empty constructor
      result = new EmptySet();
    }

    return result;
  }
View Full Code Here

Examples of org.openrdf.query.algebra.EmptySet

        if (leftArg instanceof Var && !bindingNames.contains(((Var)leftArg).getName())
            || rightArg instanceof Var && !bindingNames.contains(((Var)rightArg).getName()))
        {
          // One or both var(s) are unbound, this expression will never
          // return any results
          filter.replaceWith(new EmptySet());
          return;
        }

        if (leftArg instanceof Var && rightArg instanceof Var) {
          // Rename rightArg to leftArg
View Full Code Here

Examples of org.openrdf.query.algebra.EmptySet

      TupleExpr leftArg = join.getLeftArg();
      TupleExpr rightArg = join.getRightArg();

      if (leftArg instanceof EmptySet || rightArg instanceof EmptySet) {
        join.replaceWith(new EmptySet());
      }
      else if (leftArg instanceof SingletonSet) {
        join.replaceWith(rightArg);
      }
      else if (rightArg instanceof SingletonSet) {
View Full Code Here

Examples of org.openrdf.query.algebra.EmptySet

      }
      else if (rightArg instanceof EmptySet) {
        difference.replaceWith(leftArg);
      }
      else if (leftArg instanceof SingletonSet && rightArg instanceof SingletonSet) {
        difference.replaceWith(new EmptySet());
      }
    }
View Full Code Here

Examples of org.openrdf.query.algebra.EmptySet

    else if (projList.size() > 1) {
      result = new MultiProjection(result, projList);
    }
    else {
      // Empty constructor
      result = new EmptySet();
    }

    return result;
  }
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.