import org.apache.commons.beanutils.BeanUtils; .. .. public <T> T setParamegerBean(Class<T> clz) throws InstantiationException, IllegalAccessException, InvocationTargetException{ T t = clz.newInstance(); BeanUtils.copyProperties(t, ServletActionContext.getRequest().getParameterMap()); return t; }
제너릭 Generice Return Method 예제
2013. 6. 4. 13:13