Re: Core Data faulting and bindings: recursive KVO notifications?
Re: Core Data faulting and bindings: recursive KVO notifications?
- Subject: Re: Core Data faulting and bindings: recursive KVO notifications?
- From: Ben Trumbull <email@hidden>
- Date: Sun, 30 Mar 2008 17:24:18 -0700
Dennis,
Well, it might be far from ideal for CD performance, but that doesn't
mean it's bound poorly. It is done exactly to do what we need it to
do, otherwise this binding would have been the first to be targeted
for rewrite.
Creating a gigantic autoreleased NSArray from valueForKeyPath: and
simultaneously observing tens of thousands of objects is an awful lot
of work for little reward.
The user cannot *see* tens of thousands of things.
I really do require the app to be able to show the user the values of
about 1000 items at once, e.g. for a stack of related items. If they
are the same for every item, it is important that that value be
visible to the user.
You want distinct values, not tens of thousands of them. Too much
data is unmanageable from a user experience perspective.
Since your data is mostly read only, observing all these values is a
horrific waste. Just get the distinct values once, and invalidate
the cache in the rare case the user edits one of them.
And this is one thing Bindings as it is, cannot do properly: The
creation of all observation info (one dictionary for each bound
property of each item in the selection) when selecting is just too
much overhead. Plus you easily encounter the aforementioned stack
overflow.
You should file a bug report on this. Also, I still don't see a bug
report for your earlier problem with KVO & faulting.
Properties should be propagatable to 1000 objects at once for my
users, as they work equally with individual images and up till 1000-
image stacks.
Your 30" monitor must be a lot larger than mine.
I guess this calls for an extra layer of indirection,
with a real separate entity representing the image stack and
propagating the changes, without having 1000s of observers-observed
object relationships.
Exactly. Now that's an idea that can scale.
--
-Ben
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden