Skip navigation.
 
mlRe: Ordered lists WAS ADC Core Data article
FROM : Shawn Erickson
DATE : Fri Apr 08 21:57:01 2005

On Apr 8, 2005, at 12:40 PM, John Brownlow wrote:

> That assumes there is a key on which the objects can be sorted.
>
> But I am interested in an arbitrary order.
>
> The order my friend puts the toys in is whimsical, remember, and does
> not map to any particular quality of the toys.
>
> I do not want to have to write my friend's ordering on the toy itself
> because it may not be my toy.


Then stick it in a construct that can model this arbitrary ordering,
relationally this wouldn't be hard and is of course supported by core
data and if you are smart will work with sort descriptors so your bound
views would just work.

For example one possible modeling would be...
Entity: Friend <blah attributes>
Entity: Toy <blah attributes>
Entity: ToyOrderedListEntry <indexInOrderedList, relationship to one
Toy>
Entity: ToyOrderedList <relationship to Friend, relationship to zero or
more ToyOrderedListEntry>

etc.

-Shawn

Related mailsAuthorDate
mlOrdered lists WAS ADC Core Data article John Brownlow Apr 8, 20:09
mlRe: Ordered lists WAS ADC Core Data article John Timmer Apr 8, 21:28
mlRe: Ordered lists WAS ADC Core Data article John Brownlow Apr 8, 21:40
mlRe: Ordered lists WAS ADC Core Data article Shawn Erickson Apr 8, 21:57
mlRe: Ordered lists WAS ADC Core Data article Marcel Weiher Apr 9, 01:09
mlRe: Ordered lists WAS ADC Core Data article Scott Stevenson Apr 9, 04:55
mlRe: Ordered lists WAS ADC Core Data article Todd Blanchard Apr 9, 07:07
mlRe: Ordered lists WAS ADC Core Data article Scott Ellsworth Apr 9, 09:18