Exemple #1
0
 public static void ContainsByIdentity(object[] array, object[] expected)
 {
     for (int i = 0; i < expected.Length; i++)
     {
         if (-1 == Arrays4.IndexOfIdentity(array, expected[i]))
         {
             Assert.Fail("Expecting contains '" + expected[i] + "'.");
         }
     }
 }
 private void ImplicitlyAndJoinsOnSameField()
 {
     object[] nodes = _nodes.ToArray();
     for (int i = 0; i < nodes.Length; i++)
     {
         object node = nodes[i];
         if (node is OrIndexedLeaf)
         {
             OrIndexedLeaf current = (OrIndexedLeaf)node;
             OrIndexedLeaf other   = FindJoinOnSameFieldAtSameLevel(current);
             if (null != other)
             {
                 nodes[Arrays4.IndexOfIdentity(nodes, other)] = null;
                 CollectImplicitAnd(current.GetConstraint(), current, other);
             }
         }
     }
 }