Hi All

I have a multimap of this format...

Java Code:
import java.util.ArrayList;
import java.util.HashMap;
import java.util.Iterator;

import org.apache.commons.collections.MultiMap;
import org.apache.commons.collections.map.MultiValueMap;
public class Multitest {
	
public static void main(String args[])
{
	HashMap<String, ArrayList<String>> map =new HashMap<String, ArrayList<String>> ();
	MultiMap m = MultiValueMap.decorate(map);
	ArrayList<String> arr1=new ArrayList<String>();
	arr1.add("val1");
	arr1.add("val2");
	ArrayList<String> arr2=new ArrayList<String>();
             
	m.put("key1",arr1);
	m.put("key1",arr2);
	m.put("key2",arr1);
	m.put("key2",arr2);
	for (Iterator it = m.keySet().iterator(); it.hasNext();) {
	           String name="key1";
	            String n = (String) it.next();
	            //System.out.println(name);
	if(name.equalsIgnoreCase(n))
	        	  {
	for(Object value : (ArrayList)m.get(name)) {
		  
	                System.out.println(name+"---> "+value);
	}
	}
	}
}
}
how can i get the all the keys associated with a particular value??

For eg:val1 should give its associated keys,something like this
val1-> key1
val1-> key2

any suggestion on how to do this???