You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Chen Guoping (Jira)" <ji...@apache.org> on 2020/03/28 09:34:00 UTC

[jira] [Comment Edited] (COLLECTIONS-607) Adding a hash table based BidiMap

    [ https://issues.apache.org/jira/browse/COLLECTIONS-607?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17069161#comment-17069161 ] 

Chen Guoping edited comment on COLLECTIONS-607 at 3/28/20, 9:33 AM:
--------------------------------------------------------------------

I had provide a commit on GitHub: [https://github.com/apache/commons-collections/pull/145]
Can you help to review it ? Thanks 


was (Author: guoping):
I had provide a commit on GitHub: https://github.com/dota17/commons-collections/commit/a1b45dba11c5542de2494a2ec2d4b21dc7b39c7b
Can you help to review it ? Thanks 

> Adding a hash table based BidiMap
> ---------------------------------
>
>                 Key: COLLECTIONS-607
>                 URL: https://issues.apache.org/jira/browse/COLLECTIONS-607
>             Project: Commons Collections
>          Issue Type: New Feature
>          Components: BidiMap
>            Reporter: Rodion Efremov
>            Priority: Minor
>              Labels: features, newbie
>   Original Estimate: 336h
>          Time Spent: 10m
>  Remaining Estimate: 335h 50m
>
> In the class Javadoc of http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/bidimap/DualHashBidiMap.java?view=markup 
> there is a mention that Collections would welcome a direct hash-based implementation of BidiMap interface.
> I am working on such; my source is available at https://github.com/coderodde/BidirectionalHashMap
> At this point it does not adhere to style/interfaces of Commons Collections (such as implementing the BidiMap interface), yet I believe that is a matter of simple rewrite.
> Currently, it represents the "collision chains" as AVL-trees, thus guaranteeing O(log n) access/modification even on poor hash functions. If that is not required, rewriting would be trivial as well.
> I have several questions, but I have to start from the most important: is there any acute need for such a data structure?



--
This message was sent by Atlassian Jira
(v8.3.4#803005)