Creates a deep duplicate of any active record object, its infinitely deep descendants, and reassigns their foreign keys appropriately.