mirror of
https://gitee.com/mybatis-flex/mybatis-flex.git
synced 2025-12-08 01:28:24 +08:00
bugfix: 修改bug#I7I08X
修改equals和hashcode,加入属性所在类名,方便后续扩展使用 自测完成
This commit is contained in:
parent
7dda5963b1
commit
113a73d170
@ -300,6 +300,7 @@ public class MybatisFlexProcessor extends AbstractProcessor {
|
||||
columnInfo.setProperty(property);
|
||||
columnInfo.setColumn(columnName);
|
||||
columnInfo.setAlias(alias);
|
||||
columnInfo.setFullClassName(baseElement.getQualifiedName().toString());
|
||||
|
||||
columnInfoList.add(columnInfo);
|
||||
|
||||
|
||||
@ -41,6 +41,8 @@ public class ColumnInfo {
|
||||
*/
|
||||
private String[] alias;
|
||||
|
||||
private String fullClassName;
|
||||
|
||||
public String getProperty() {
|
||||
return property;
|
||||
}
|
||||
@ -65,16 +67,24 @@ public class ColumnInfo {
|
||||
this.alias = alias;
|
||||
}
|
||||
|
||||
public String getFullClassName() {
|
||||
return fullClassName;
|
||||
}
|
||||
|
||||
public void setFullClassName(String fullClassName) {
|
||||
this.fullClassName = fullClassName;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean equals(Object o) {
|
||||
if (this == o) return true;
|
||||
if (o == null || getClass() != o.getClass()) return false;
|
||||
ColumnInfo that = (ColumnInfo) o;
|
||||
return Objects.equals(property, that.property);
|
||||
return Objects.equals(property, that.property) && Objects.equals(fullClassName, that.fullClassName);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return Objects.hash(property);
|
||||
return Objects.hash(property, fullClassName);
|
||||
}
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user