Page 1 of 1

What's the diff between concurrentHashMap and FastMap.shared

Posted: Mon May 26, 2014 5:33 am
by yksdtc
they all both thread safe。
am I right?

Re: What's the diff between concurrentHashMap and FastMap.sh

Posted: Mon May 26, 2014 6:28 am
by NosBit
Yes but FastMap is sorted its like a thread-safe LinkedHashMap

Re: What's the diff between concurrentHashMap and FastMap.sh

Posted: Mon May 26, 2014 6:44 pm
by Zoey76
Nos wrote:Yes but FastMap is sorted its like a thread-safe LinkedHashMap
FastMap is sorted by insert order, the other "thread-safe" sorted map is ConcurrentSkipListMap which is sorted by natural order of keys.

Also FastMap is concurrent, and does not imply thread-safe, unless specified calling shared.