Example #1
0
        private static void CheckDuplicateOrAdd(
            QueryPlanIndexItemForge proposed,
            IList<QueryPlanIndexItemForge> indexesSet)
        {
            var found = false;
            foreach (var index in indexesSet) {
                if (proposed.EqualsCompareSortedProps(index)) {
                    found = true;
                    break;
                }
            }

            if (!found) {
                indexesSet.Add(proposed);
            }
        }
 private static void CompareIndexItem(
     int stream,
     int num,
     QueryPlanIndexItemForge expectedIndex,
     QueryPlanIndexItemForge actualIndex)
 {
     if (!expectedIndex.EqualsCompareSortedProps(actualIndex)) {
         Assert.Fail(
             "At stream " +
             stream +
             " index " +
             num +
             "\nExpected:\n" +
             expectedIndex +
             "\n" +
             "Received:\n" +
             actualIndex +
             "\n");
     }
 }