Deep Copy is a built in operation on which Lombardi Teamworks/IBM BPM relies heavily in an automated manner, whenever a pass by value takes place a deep copy operation is done by the process server. it basically serializes the object and then deserializes to get a non referenced exact copy of the object. Deep copy is a resource intensive process that is why it is recommended to skinny down your complex large BOs especially when pass by value happens, or to nullify the not needed BOs.
The syntax in JSApis as follows
tw.local.newVariable = tw.system.serializer.fromXml ( tw.system.serializer.toXml ( tw.local.somevariable ) );
after this operation the newVariable will hold an exact copy of somevariable but ther will be no linkage by reference and the two objects will be disassociated