java删除map的键值对,json对象转map
//*
类a {
publicstaticobjectmaptoobject (映射,类bean类) throws Exception {
if (映射==空) )。
返回空值;
org.Apache.com mons.beanutils.beanutils.populate (obj,map );
返回对象;
}
公共静态地图, 对象主题图(对象主题图) {
if(obj==null ) )。
返回空值;
return new org.Apache.com mons.beanutils.bean map (obj )
}
}
//*
类b {
publicstaticobjectmaptoobject (映射,类bean类) throws Exception {
if (映射==空) )。
返回空值;
beaninfobeaninfo=introspect or.getbeaninfo (obj.getclass ) );