I have hashmap Key is String composed of concatenation of 3 elements (element1+element2+element3)
String key=element1+element2+element3;
which is put in the hashmap
HashMap<String,Object> map=new Hashmap<String,Object>();
map.put(key,new Object());
i want to remove all the entries in the hashmap matching key having element2 if(key.contains("element2")) then remove that entry in hashmap.
How accomplish this?