TreeDiff constructor
Implementation
factory TreeDiff({required ITreeNode oldTree, required ITreeNode newTree}) {
if (oldTree is TreeNode && newTree is TreeNode)
return forTree(oldTree: oldTree, newTree: newTree);
if (oldTree is IndexedTreeNode && newTree is IndexedTreeNode)
return forIndexedTree(oldTree: oldTree, newTree: newTree);
return TreeDiff._(oldTree: oldTree, newTree: newTree);
}