Re: Faking large arrays in bindings to satisfy sparse data...
Re: Faking large arrays in bindings to satisfy sparse data...
- Subject: Re: Faking large arrays in bindings to satisfy sparse data...
- From: mmalcolm crawford <email@hidden>
- Date: Sat, 19 Mar 2005 18:40:36 -0800
On Mar 19, 2005, at 6:01 PM, アンドレ(Andre) wrote:
Please don't cross-post.
Follow-ups to email@hidden.
For example, say I only have two items in my sparse array, but the
second item is in position 33. If I have my object return
countOf<Key> to return 33 would that be good enough?
When the controller gets a change to another position below 33 I
could handle it and
abstract it with objectIn<Key>AtIndex: etc, but what I am worried
about is anything above
33.... what would happen if I returned INT_MAX for countOf<key>
would that cause the
NSArrayController to allocate space for 2 billion items?? Or is it
smart enough?
What happens if you try it?
(Hint: Why would the array controller allocate space for the objects?)
Is there any way to do this besides getting all the items in a
given array, iterate their "position" key to find the ones I want
changed or removed??
How are you managing your sparse array? If you know the indexes of
the items in your array, then you should be able to do whatever is
appropriate in the indexed accessor methods?
mmalc
_______________________________________________
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