public Map<String, Object> getData(HttpServletRequest request) throws Exception{
Map<String,Object> map = new HashMap<String, Object>();
Map<String, String[]> mapData = request.getParameterMap();
Iterator it = mapData.keySet().iterator();
while (it.hasNext()){
Map.Entry<String, String[]> entry = (Map.Entry<String, String[]>) it.next();
for (String v: entry.getValue())
map.put(entry.getKey(), this.isEmpty(v)?null:v);
}
return map;
}
public boolean isEmpty(String str) {
boolean bool = false;
if( str == null || str.isEmpty() || "".equals(str)) {
bool = true;
}
return bool;
}