} if (meta != null) { int colCount = meta.getColumnCount(); for (int i = 1; i <= colCount; i++) { String fieldName = meta.getColumnName(i); Object fieldValue = rs.getString(fieldName); m.put(fieldName, fieldValue); fieldName = null; fieldValue = null; } } list.add(m); m = null; meta = null; } }); } catch (Exception e) { e.printStackTrace(); } return list; } /** * 需要实现此方法,返回一个SpringJdbcTemplate对象 */ private JdbcTemplate getSpringJdbcTemplate() { //TODO return null; }