import java.beans.Introspector;
import java.beans.PropertyDescriptor;
//获取java bean
PropertyDescriptor[] props = null;try {
props = Introspector.getBeanInfo(Bean.getClass(), Object.class).getPropertyDescriptors();
if (props != null) {
for (int i = 0; i < props.length; i++) {
String aa = props[i].getName();//获取bean中的属性
Object object = props[i].getPropertyType();//获取属性的类型
}
}
} catch (Exception e) {
}