Пример #1
0
 public TreeNodeBenchmark()
 {
     TreeNodeRoot       = TreeNode.CreateTree(TreeDepth);
     TreeNodeStructRoot = TreeNodeStruct.CreateTree(TreeDepth);
     if (TreeNodeRoot.CountNodes() != TreeNodeStructRoot.CountNodes())
     {
         throw new InvalidOperationException("Node count doesn't match.");
     }
 }
Пример #2
0
 public NodeData(TreeNodeStruct left, TreeNodeStruct right)
 {
     Left  = left;
     Right = right;
 }
Пример #3
0
 public void CreateTreeNodeStructs()
 {
     TreeNodeStruct.CreateTree(TreeDepth);
 }
Пример #4
0
 public TreeNodeStruct(TreeNodeStruct left, TreeNodeStruct right)
 {
     Data = new NodeData(left, right);
 }