How can I make a deep copy in Objective-C?

前端 未结 6 1691
爱一瞬间的悲伤
爱一瞬间的悲伤 2020-12-05 14:03

I\'m learning ios development and I\'m confused with deep copying in Objective-C. For example,I have three class below. Now I want to deep copy ClassA, can anybody teach me

6条回答
  •  广开言路
    2020-12-05 14:59

    This could be of some help. The link shows how to do the deep copy using NSKeyedArchiver

    http://iphonecodecenter.wordpress.com/2013/08/26/difference-between-shallow-copy-and-deep-copy/

提交回复
热议问题