我在哪里可以找到的Java标准的特里基于地图的实现? [英] Where do I find a standard Trie based map implementation in Java?

查看:128
本文介绍了我在哪里可以找到的Java标准的特里基于地图的实现?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个存储了大量的映射从字符串到各种对象的Java程序。

I have a Java program that stores a lot of mappings from Strings to various objects.

现在,我的选择是要么依赖(通过HashMap的)或二进制搜索(通过TreeMap中)散列。我想知道是否有一个流行及品质的集合库的高效,规范线索为基础的Map实现?

Right now, my options are either to rely on hashing (via HashMap) or on binary searches (via TreeMap). I am wondering if there is an efficient and standard trie-based map implementation in a popular and quality collections library?

我已经写了我自己的过去,但我宁愿用什么标准去了,如果有的话。

I've written my own in the past, but I'd rather go with something standard, if available.

快速澄清:虽然我的问题是,一般情况下,在当前项目中,我处理大量的数据,是通过完全限定类名或方法签名索引。因此,有许多共享prefixes。

Quick clarification: While my question is general, in the current project I am dealing with a lot of data that is indexed by fully-qualified class name or method signature. Thus, there are many shared prefixes.

推荐答案

您可能想要看的特里实现,LimeWire的是促进到谷歌番石榴。

You might want to look at the Trie implementation that Limewire is contributing to the Google Guava.

这篇关于我在哪里可以找到的Java标准的特里基于地图的实现?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆