Exemplo n.º 1
0
        public override DataTable GetSkylineTable(String querySQL, String preferenceOperators)
        {
            DataTable dt;

            if (HasIncomparablePreferences)
            {
                //Hexagon incomparable needs additional parameters
                SPSkylineHexagon skyline = new SPSkylineHexagon();

                AdditionParameters[4] = AdditionParameters[4].Trim().Replace("''", "'").Trim('\'');
                //Change operators array and SQL query (replace INCOMPARABLES values)
                skyline.CalculateOperators(ref preferenceOperators, AdditionParameters, ConnectionString, Provider, ref querySQL);

                dt = skyline.GetSkylineTable(querySQL, preferenceOperators, RecordAmountLimit, true, ConnectionString, Provider, AdditionParameters, SortType);
                TimeMilliseconds    = skyline.TimeInMs;
                NumberOfComparisons = skyline.NumberOfOperations;
                NumberOfMoves       = skyline.NumberOfMoves;
            }
            else
            {
                SPSkylineHexagonLevel skyline = new SPSkylineHexagonLevel();
                dt = skyline.GetSkylineTable(querySQL, preferenceOperators, RecordAmountLimit, true, ConnectionString, Provider, AdditionParameters, SortType);
                TimeMilliseconds    = skyline.TimeInMs;
                NumberOfComparisons = skyline.NumberOfOperations;
                NumberOfMoves       = skyline.NumberOfMoves;
            }
            return(dt);
        }
Exemplo n.º 2
0
        public override DataTable GetSkylineTable(String querySQL, String preferenceOperators)
        {
            DataTable dt;
            if (HasIncomparablePreferences)
            {
                //Hexagon incomparable needs additional parameters
                SPSkylineHexagon skyline = new SPSkylineHexagon();

                AdditionParameters[4] = AdditionParameters[4].Trim().Replace("''", "'").Trim('\'');
                //Change operators array and SQL query (replace INCOMPARABLES values)
                skyline.CalculateOperators(ref preferenceOperators, AdditionParameters, ConnectionString, Provider, ref querySQL);

                dt = skyline.GetSkylineTable(querySQL, preferenceOperators, RecordAmountLimit, true, ConnectionString, Provider, AdditionParameters, SortType);
                TimeMilliseconds = skyline.TimeInMs;
                NumberOfComparisons = skyline.NumberOfOperations;
                NumberOfMoves = skyline.NumberOfMoves;
            }
            else
            {
                SPSkylineHexagonLevel skyline = new SPSkylineHexagonLevel();
                dt = skyline.GetSkylineTable(querySQL, preferenceOperators, RecordAmountLimit, true, ConnectionString, Provider, AdditionParameters, SortType);
                TimeMilliseconds = skyline.TimeInMs;
                NumberOfComparisons = skyline.NumberOfOperations;
                NumberOfMoves = skyline.NumberOfMoves;
            }
            return dt;
        }
Exemplo n.º 3
0
 public static void GetSkyline(SqlString strQuery, SqlString strOperators, SqlInt32 numberOfRecords, SqlInt32 sortType)
 {
     SPSkylineHexagonLevel skyline = new SPSkylineHexagonLevel();
     string[] additionalParameters = new string[1];
     //additionalParameters[0] = strFirstSQLHexagon;
     //additionalParameters[1] = strOperatorsHexagon;
     //additionalParameters[2] = "";
     //additionalParameters[3] = "0";
     skyline.GetSkylineTable(strQuery.ToString(), strOperators.ToString(), numberOfRecords.Value, false, Helper.CnnStringSqlclr, Helper.ProviderClr, additionalParameters, sortType.Value);
 }
Exemplo n.º 4
0
        public static void GetSkyline(SqlString strQuery, SqlString strOperators, SqlInt32 numberOfRecords, SqlInt32 sortType)
        {
            SPSkylineHexagonLevel skyline = new SPSkylineHexagonLevel();

            string[] additionalParameters = new string[1];
            //additionalParameters[0] = strFirstSQLHexagon;
            //additionalParameters[1] = strOperatorsHexagon;
            //additionalParameters[2] = "";
            //additionalParameters[3] = "0";
            skyline.GetSkylineTable(strQuery.ToString(), strOperators.ToString(), numberOfRecords.Value, false, Helper.CnnStringSqlclr, Helper.ProviderClr, additionalParameters, sortType.Value);
        }