Re: Copying id

2008-08-11 Thread Ken Ferry
On Mon, Aug 11, 2008 at 8:22 PM, Ken Ferry <[EMAIL PROTECTED]> wrote: > On Mon, Aug 11, 2008 at 7:15 PM, Mike <[EMAIL PROTECTED]> wrote: >> Ken Thomases wrote: >>> >>> On Aug 10, 2008, at 2:05 AM, Mike wrote: >>> How does one go about copying an object specified by id when one doesn't kno

Re: Copying id

2008-08-11 Thread Ken Ferry
On Mon, Aug 11, 2008 at 7:15 PM, Mike <[EMAIL PROTECTED]> wrote: > Ken Thomases wrote: >> >> On Aug 10, 2008, at 2:05 AM, Mike wrote: >> >>> How does one go about copying an object specified by id when one doesn't >>> know the object type and the object does not implement NSCopying protocol? >> >>

Re: Copying id

2008-08-11 Thread Graham Cox
On 12 Aug 2008, at 12:15 pm, Mike wrote: Both the key and value for each key in the items in my array can be of any object type (id). The sorted key/value paid array class has to be able to make copies of the items in the arrays when it goes to sort them. Since the array class has to be ge

Re: Copying id

2008-08-11 Thread Charles Srstka
On Aug 11, 2008, at 9:15 PM, Mike wrote: Because, I have a case where I need to create my own object for storing key/value pairs in a sorted array. Since NSDictionary, etc. doesn't allow sorted elements in the dictionary, I have to define my own - but in an array instead of a dictionary.

Re: Copying id

2008-08-11 Thread Mike
Ken Thomases wrote: On Aug 10, 2008, at 2:05 AM, Mike wrote: How does one go about copying an object specified by id when one doesn't know the object type and the object does not implement NSCopying protocol? The short answer is: you don't. If an object's class doesn't implement NSCopying,

Re: Copying id

2008-08-10 Thread Ken Thomases
On Aug 10, 2008, at 2:05 AM, Mike wrote: How does one go about copying an object specified by id when one doesn't know the object type and the object does not implement NSCopying protocol? The short answer is: you don't. If an object's class doesn't implement NSCopying, then there are no

Copying id

2008-08-10 Thread Mike
How does one go about copying an object specified by id when one doesn't know the object type and the object does not implement NSCopying protocol? Thanks, Mike ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests