You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by GitBox <gi...@apache.org> on 2022/08/14 08:07:33 UTC

[GitHub] [netbeans] tonihele commented on pull request #4502: #4500 static imported methods slow down auto completion

tonihele commented on PR #4502:
URL: https://github.com/apache/netbeans/pull/4502#issuecomment-1214307696

   Could the performance still be increased if hashing is used instead of just traversing the methods list in a loop to find matches? Or with binary search? I don't know how many methods there are in average to take full advantage of this approach. But at least it would stay logarithmic.
   
   If this is changed into a Hashmap:
   `List<ExecutableElement> methodsIn = null;`
   
   And possibly a local wrapper class around ExecutableElement to create the appropriate `hashCode`  and `equals` to serve the purpose? Or with binary search (`Collections.binarySearch()`) just create the comparer with no need of wrapping and sort once of course.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists