I don’t think we are going to make Document or other classes [Serializable] unless we find a good reason for it. Document can be save (read serialized) into DOC format at the moment and WordML and RTF will also be supported “serialization” formats later on.
All nodes provide the public Clone method already (derived from Node.Clone). We don’t explicitly implement the ICloneable interface because of some interesting guidelines I find in the MSDN blogs http://blogs.msdn.com/brada/archive/2003/04/09/49935.aspx
Thanks for the information there.
Does the Node.Clone() method do a deep or shallow copy?
Our Clone always creates a complete duplicate (deep clone) of the original node.
Note the boolean parameter isDeep - it controls whether to clone the child nodes, not the “shallowness or deepness”. So you always receive a deep clone, but it can be with or without its children. I shall probably rename isDeep into isCloneChildren later to avoid this confusion.