Re: multiple inheritance equivalent in Core Data?
Re: multiple inheritance equivalent in Core Data?
- Subject: Re: multiple inheritance equivalent in Core Data?
- From: Bob Ippolito <email@hidden>
- Date: Mon, 9 May 2005 14:09:56 -0400
On May 9, 2005, at 12:48 PM, glenn andreas wrote:
On May 9, 2005, at 11:40 AM, John Timmer wrote:
I don't have Tiger yet and haven't looked at CoreData much but I
hope
that won't matter much. Under Panther I would use protocols to
encapsulate these behaviors because a class can conform to multiple
protocols.
To be more clear, in every place I said "keys", you could read
"instance
variables". My understanding is that neither protocols or
categories can
add instance variables to a class, so that neither of these would
work for
this situation.
If you always access instance variables via accessors, categories
can add them to a class (by maintaining the state in a separate
data structure).
Consider "retainCount" as an example.
The question really sounds like premature optimization though. I
wouldn't care whether CoreData wants me to have an extra ivar or
two. God forbid those extra few bytes are wasted per instance, when
there's a chance it might not even matter since allocations are
vector aligned :)
-bob
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden