Deep Copy a .NET Class Instance Without Serialization

前端 未结 3 707
轻奢々
轻奢々 2021-02-15 16:33

I am using an instance class from a third-party DLL, and I need to do a deep copy on a particular instance. The class is not marked as Serializable, and therefore

3条回答
  •  滥情空心
    2021-02-15 16:44

    I've been using Copyable with great success. It uses reflection under the hood. It is open-sourced. Be sure to read Limitations and pitfalls to see if you can use it.

提交回复
热议问题