Re: [android-developers] How to abort slow array sorting

2010-09-07 Thread Kostya Vasilyev

 07.09.2010 16:00, ls02 пишет:

I sort very long array with Collections.sort method. This is done in a
worker thread. I need to abort the sort. I didn't find how I can do
this, Comparator.compare does not seem to allow throwing any exception
and I didn't find how I can set any flag to abort the sort.



You can throw a subclass of RuntimeException, even if the method 
signature doesn't allow it.


--

Kostya Vasilyev -- WiFi Manager + pretty widget -- http://kmansoft.wordpress.com


--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] How to abort slow array sorting

2010-09-07 Thread ls02
I sort very long array with Collections.sort method. This is done in a
worker thread. I need to abort the sort. I didn't find how I can do
this, Comparator.compare does not seem to allow throwing any exception
and I didn't find how I can set any flag to abort the sort.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en