GoDiagram Win Reference
Copy Method (GoCopyDictionary)

Return a copied object for an object (first pass only).
Syntax
'Declaration
 
Public Overridable Function Copy( _
   ByVal obj As GoObject _
) As GoObject
public virtual GoObject Copy( 
   GoObject obj
)

Parameters

obj
Remarks

First this method looks up obj in its mapping table--if it finds an object, it returns it, because presumably it has already been copied. Otherwise it calls GoObject.GoObject.CopyObject in order to make a copy of obj. If obj is null, this returns null.

The primary use of this method is to be called by GoDocument's GoDocument.CopyFromCollection(IGoCollection, bool, bool, SizeF, GoCopyDictionary) method. This is also typically called within a GoObject.CopyObject override method to make a copy of a referenced object that is not a child of the copied object.

If you don't call this in the context of a GoDocument.CopyFromCollection(IGoCollection, bool, bool, SizeF, GoCopyDictionary) method, be sure to call FinishDelayedCopies afterwards to perform the second copying pass, which resolves references and can do other copying work as implemented by GoObject.GoObject.CopyObjectDelayed.

The easiest way to make a full copy of an object in a document is to call GoDocument.GoDocument.AddCopy, which calls CopyFromCollection. However, if you want to create a copy of an object without adding it to a document, you can call CopyComplete, which performs both copying passes.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

GoCopyDictionary Class
GoCopyDictionary Members

 

 


© 2015. Northwoods Software Corporation. All Rights Reserved.

Send Feedback