Hi Christer, On 06/27/10 10:36, Christer wrote: > Whats a smart way of aborting sorting a list? I have objects in a ArrayList > being sorted using the Comparable interface. My application is handling > millions of items being sorted and I sometimes would like to abort the > sorting if the user chooses to do something else.
Indeed, I think none ever submitted a such use-case. Should the original list be left untouched in case of cancellation ? In that case, a temporary view should be used instead of the original list. Else, the original list would be left partially sorted (which might not be a problem for certain use-cases). Then I guess sort() could also be defined as an async method with an additional Cancellable argument. Would that fit your use-case ? > And thanks for Vala and Gee once again, Im loving the speed of them both and > plan to use them for many projects on Linux. :) Glad to hear that :) Best regards, Didier. _______________________________________________ vala-list mailing list [email protected] http://mail.gnome.org/mailman/listinfo/vala-list
