public void onItemClick(AdapterView<?> parent, View view, int position,
long id) {
System.out.println("当前值:"+position);
Map<String, String> temp = map.get(position);
//temp是该选项的内容
另外,以下是Android中如何迭带出ArrayList<HashMap<String,Object>>中hashmap里的键值对的方法:
ArrayList<HashMap<String,Object>> list=new ArrayList<HashMap<String,Object>>(10);
Iterator<HashMap<String,Object>> it= list.iterator();
HashMap<String,Object> hash;
String key;
Object value;
Iterator<String> set;
while(it.hasNext()){
hash=it.next();
set=hash.keySet().iterator();
while(set.hasNext()){
key=set.next();
value=hash.get(key);
//以下为对key和value的具体处理