mybatis-generator-gui icon indicating copy to clipboard operation
mybatis-generator-gui copied to clipboard

建议把List更换为Collection

Open songlongkuan opened this issue 5 years ago • 0 comments

例如在使用in查询的时候 自动生成的api是这样的
public Criteria andDyUserIdIn(List<String> values) { addCriterion("dy_user_id in", values, "dyUserId"); return (Criteria) this; } 建议把这个List 换成 Collection ,往往有时候我们对某些数据去重后,大部分会采用Set容器,这样的话 调这种类型的api 还得new ArrayList ,所以 这里建议直接采用Collection类型的集合

songlongkuan avatar Mar 07 '19 07:03 songlongkuan