Class HeuristicsCalculator


  • public class HeuristicsCalculator
    extends Object
    • Constructor Detail

      • HeuristicsCalculator

        public HeuristicsCalculator​(SqlNameContext context)
    • Method Detail

      • computeDistance

        public static double computeDistance​(String statement,
                                             QueryResult data)
      • computeExpression

        public double computeExpression​(net.sf.jsqlparser.expression.Expression exp,
                                        DataRow data)
        Compute a "branch" distance heuristics.
        Parameters:
        exp - the WHERE clause which we want to resolve as true
        data - current data raw in the database, based on the columns/tables involved in the WHERE
        Returns:
        a branch distance, where 0 means that the data would make the WHERE resolves to true