Wednesday, January 21, 2015

Re: SuggestBox: how to change suggestions sort order?


Were you able to find a solution to this at all? I have been trying to figure this out all week, but I am still stuck. When I try to extend SuggestOracle and implement my own Oracle, I am having problems with some of the methods being private and classes (PrefixTree) with default access modifier . It would be great if someone could point me in the right direction. Thanks.


On Thursday, January 28, 2010 at 9:28:28 AM UTC-7, forewar wrote:
I have the following problem:
I have created SuggestBox element and filled it`s
MultiWordSuggestOracle. But when I use showSuggestionList(), my
suggestions are displaying in alphabetic order instead of original
order. I want to show suggestions depends on their rating, not in
alphabetic order.
So, maybe someone could help me? I suppose, it must be some mechanism
to set displaying order, but I havent found it in docs yet.

My code is quite simple:
AsyncCallback<ArrayList> callback = new AsyncCallback<ArrayList>() {
          public void onSuccess(ArrayList result){
            ArrayList suggests = result;
            Iterator suggestsIt = suggests.iterator();
            MultiWordSuggestOracle ora = getOracleByElementId

I`m sure that element of my ArrayList suggests are sorted in order I
want. But oracle changes it.

You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
To post to this group, send email to
Visit this group at
For more options, visit

No comments:

Post a Comment