Collections.Map.Concurrent

Description

Concurrent Map functions

Functions

NameSignature and Synopsis
createConcurrentHashMapObject createConcurrentHashMap ( )
Create and return instance of ConcurrentHashMap.
This function returns a thread safe hash map.
createHashMapWithIdObject createHashMapWithId ( String mapId )
Create and return instance of ConcurrentHashMap.
putIfAbsentObject putIfAbsent ( Object map ,Object key ,Object value )
If the specified key is not already associated with a value, associate it with the given value. The action is performed atomically.
removeboolean remove ( Object map ,Object key ,Object value )
Remove entry for key only if currently mapped to given value. The action is performed atomically.
replaceObject replace ( Object map ,Object key ,Object value )
Replace entry for key only if currently mapped to some value. The action is performed atomically.
replaceIfEqualToGivenValueboolean replaceIfEqualToGivenValue ( Object map ,Object key ,Object oldValue, Object newValue )
Replace entry for key only if currently mapped to given value. The action is performed atomically.