feat[version]: use javassist to enhance version interface

This commit is contained in:
godotg
2024-07-01 13:53:03 +08:00
parent 1cb440a5f6
commit a79fdfceda
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -75,7 +75,7 @@ public class EntityCache<PK extends Comparable<PK>, E extends IEntity<PK>> imple
version = cacheVersionReflect;
} else {
try {
version = EnhanceUtils.createEventReceiver(cacheVersionReflect);
version = EnhanceUtils.createVersion(cacheVersionReflect);
} catch (Exception e) {
throw new RuntimeException(e);
}
@@ -42,7 +42,7 @@ public abstract class EnhanceUtils {
}
}
public static IVersion createEventReceiver(VersionReflect cacheVersion) throws NotFoundException, CannotCompileException, NoSuchMethodException, IllegalAccessException, InvocationTargetException, InstantiationException {
public static IVersion createVersion(VersionReflect cacheVersion) throws NotFoundException, CannotCompileException, NoSuchMethodException, IllegalAccessException, InvocationTargetException, InstantiationException {
var classPool = ClassPool.getDefault();
Class<?> clazz = cacheVersion.getEntityClass();