cn.foxtech.common.entity.utils.ExtendConfigUtils Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of fox-edge-server-common-entity-service Show documentation
Show all versions of fox-edge-server-common-entity-service Show documentation
fox-edge-server-common-entity-service
package cn.foxtech.common.entity.utils;
import cn.foxtech.common.entity.constant.DeviceMapperVOFieldConstant;
import cn.foxtech.common.entity.constant.DeviceVOFieldConstant;
import cn.foxtech.common.entity.entity.*;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
public class ExtendConfigUtils {
public static Map getExtendConfigList(List extendConfigEntityList, Class clazz) {
Map result = new HashMap<>();
for (BaseEntity entity : extendConfigEntityList) {
ExtendConfigEntity extendConfigEntity = (ExtendConfigEntity) entity;
if (clazz.equals(DeviceEntity.class) || clazz.equals(DeviceMapperEntity.class)) {
if (extendConfigEntity.getExtendType().equals(clazz.getSimpleName() + "Globe")) {
result.put("Globe", extendConfigEntity);
continue;
}
if (extendConfigEntity.getExtendType().equals(clazz.getSimpleName() + "Type")) {
result.put("Type", extendConfigEntity);
continue;
}
if (extendConfigEntity.getExtendType().equals(clazz.getSimpleName() + "Object")) {
result.put("Object", extendConfigEntity);
continue;
}
}
}
return result;
}
public static void extendMapList(List
© 2015 - 2025 Weber Informatics LLC | Privacy Policy