Re: mutable deep copying?
Re: mutable deep copying?
- Subject: Re: mutable deep copying?
- From: Greg Titus <email@hidden>
- Date: Sun, 28 Jul 2002 12:56:01 -0700
On Sunday, July 28, 2002, at 12:35 PM, Daryn wrote:
It seems that [myDict copy] results in a deep copy, while [myDict
mutableCopy] results in a shallow, yet mutable, copy. What I need is
a mutable deep copy of the dictionary.
My data structure is composed of simple dictionaries, arrays, and
strings. Is there a simple method by which I may obtain a mutable copy
of the entire data structure? Or do I need to implement my own
protocol to do this?
There is no simple way to do this built into the Cocoa frameworks, but
it isn't that difficult to implement it yourself.
Or, you can use ours. There is a -deepMutableCopy implementation for
those classes in OmniFoundation.
Hope this helps,
-Greg
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.