feat: 项目整体命名修改cache-schema-checker
All checks were successful
缓存序列化结构检查 / cache-schema-check (push) Has been skipped

This commit is contained in:
2026-07-14 11:03:34 +08:00
parent 114b053733
commit 110beb79c0
42 changed files with 197 additions and 199 deletions

View File

@@ -0,0 +1,56 @@
package com.codechecker.cache.schema;
import java.util.Objects;
/**
* 扁平化后的单个字段节点。path 使用点号分隔,数组元素以 {@code []} 标记。
* 例如:{@code vo.linkList[].id}。
*/
public class FieldSchema {
private final String path;
private final JsonType jsonType;
private final String javaType;
public FieldSchema(String path, JsonType jsonType, String javaType) {
this.path = path;
this.jsonType = jsonType;
this.javaType = javaType;
}
public String getPath() {
return path;
}
public JsonType getJsonType() {
return jsonType;
}
public String getJavaType() {
return javaType;
}
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (!(o instanceof FieldSchema)) {
return false;
}
FieldSchema that = (FieldSchema) o;
return Objects.equals(path, that.path)
&& jsonType == that.jsonType
&& Objects.equals(javaType, that.javaType);
}
@Override
public int hashCode() {
return Objects.hash(path, jsonType, javaType);
}
@Override
public String toString() {
return path + ":" + jsonType + "(" + javaType + ")";
}
}