ibaits源码中缓存列名的地方在这里:
com.ibatis.sqlmap.engine.mapping.result .AutoResultMap
public synchronized Object[] getResults(StatementScope statementScope, ResultSet rs)
throws SQLException {
if (allowRemapping || getResultMappings() == null) {
initialize(rs);
return super.getResults(statementScope, rs);
}
处理方法:给动态的字段起个别名
本文介绍ibatis源码中缓存列名的具体位置及处理方法,针对AutoResultMap类中的getResults方法进行深入剖析,讲解如何为动态字段设置别名。
2928

被折叠的 条评论
为什么被折叠?



