Github user guidotag commented on the pull request:

    https://github.com/apache/lucenenet/pull/92#issuecomment-73944065
  
    I realized that there are two different implementations of a PQ, one in 
Util and this one in Support. Do we have two different ones for some reason? A 
couple of things I've noticed:
    
    - The Java version uses the Util's PQ. Moreover there seems to be no 
Support package, which seems to contain emulations of Java features not present 
in C#. 
    - The Support's one is only used in the Search/TopTermsRewrite class. The 
Util's one is much more referenced.
    - The only PQ's methods invoked from TopTermsRewrite are: PriorityQueue(int 
capacity), PriorityQueue(), T Peek(), T Poll() (dequeueing without failure if 
the PQ is empty), bool Offer(T item) (insertion) and int Count. All of these 
methods are provided by Util's PQ, with the exception of Poll which could be 
added with little effort.
    
    All this facts make me think that we should replace the Support's duplicate 
by the Util's preexisting PQ. 



---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to