| | |
| | | package com.qianwen.smartman.modules.notify.service.impl; |
| | | |
| | | import cn.hutool.core.collection.CollectionUtil; |
| | | import cn.hutool.core.util.ObjectUtil; |
| | | import com.baomidou.mybatisplus.core.conditions.Wrapper; |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import java.lang.invoke.SerializedLambda; |
| | | import java.util.ArrayList; |
| | | import java.util.HashMap; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | import java.util.Optional; |
| | | import java.util.stream.Collectors; |
| | | |
| | | import org.slf4j.Logger; |
| | | import org.slf4j.LoggerFactory; |
| | | import com.qianwen.smartman.common.constant.CommonConstant; |
| | | import com.qianwen.smartman.common.constant.NotifyConstant; |
| | | import com.qianwen.smartman.common.utils.MessageUtils; |
| | | import org.springframework.context.annotation.Lazy; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.Wrapper; |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.qianwen.core.cache.utils.CacheUtil; |
| | | import com.qianwen.core.log.exception.ServiceException; |
| | | import com.qianwen.core.mp.base.BaseServiceImpl; |
| | |
| | | import com.qianwen.core.notify.notifier.NotifierProvider; |
| | | import com.qianwen.core.tool.metadata.ConfigMetadata; |
| | | import com.qianwen.core.tool.utils.Func; |
| | | import com.qianwen.smartman.common.constant.CommonConstant; |
| | | import com.qianwen.smartman.common.constant.NotifyConstant; |
| | | import com.qianwen.smartman.common.utils.MessageUtils; |
| | | import com.qianwen.smartman.modules.notify.api.DingTalkApi; |
| | | import com.qianwen.smartman.modules.notify.dto.NotifyTypeInfo; |
| | | import com.qianwen.smartman.modules.notify.dto.ProviderInfo; |
| | |
| | | import com.qianwen.smartman.modules.sync.constant.OuterAppConfigConstant; |
| | | import com.qianwen.smartman.modules.sync.entity.OuterAppConfig; |
| | | import com.qianwen.smartman.modules.sync.service.IOuterAppConfigService; |
| | | import org.springframework.context.annotation.Lazy; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import cn.hutool.core.collection.CollectionUtil; |
| | | import cn.hutool.core.util.ObjectUtil; |
| | | |
| | | @Service |
| | | /* loaded from: blade-api.jar:BOOT-INF/classes/org/springblade/modules/notify/service/impl/NotifyConfigServiceImpl.class */ |
| | | |
| | | public class NotifyConfigServiceImpl extends BaseServiceImpl<NotifyConfigMapper, NotifyConfigEntity> implements INotifyConfigService { |
| | | private static final Logger log = LoggerFactory.getLogger(NotifyConfigServiceImpl.class); |
| | | private final BusinessNotifyMapper notifyBusinessMapper; |
| | | private final List<NotifierProvider> providers; |
| | | private final DingTalkApi dingTalkApi; |
| | | private final IOuterAppConfigService outerAppConfigService; |
| | | |
| | | private static /* synthetic */ Object $deserializeLambda$(SerializedLambda lambda) { |
| | | String implMethodName = lambda.getImplMethodName(); |
| | | boolean z = true; |
| | | switch (implMethodName.hashCode()) { |
| | | case -1462663655: |
| | | if (implMethodName.equals("getNotifyType")) { |
| | | z = true; |
| | | break; |
| | | } |
| | | break; |
| | | case -631689286: |
| | | if (implMethodName.equals("getNotifyId")) { |
| | | z = false; |
| | | break; |
| | | } |
| | | break; |
| | | case -75106384: |
| | | if (implMethodName.equals("getType")) { |
| | | z = true; |
| | | break; |
| | | } |
| | | break; |
| | | case 98245393: |
| | | if (implMethodName.equals("getId")) { |
| | | z = true; |
| | | break; |
| | | } |
| | | break; |
| | | case 803533544: |
| | | if (implMethodName.equals("getStatus")) { |
| | | z = true; |
| | | break; |
| | | } |
| | | break; |
| | | } |
| | | switch (z) { |
| | | case false: |
| | | if (lambda.getImplMethodKind() == 5 && lambda.getFunctionalInterfaceClass().equals("com/baomidou/mybatisplus/core/toolkit/support/SFunction") && lambda.getFunctionalInterfaceMethodName().equals("apply") && lambda.getFunctionalInterfaceMethodSignature().equals("(Ljava/lang/Object;)Ljava/lang/Object;") && lambda.getImplClass().equals("org/springblade/modules/notify/entity/BusinessNotify") && lambda.getImplMethodSignature().equals("()Ljava/lang/Long;")) { |
| | | return (v0) -> { |
| | | return v0.getNotifyId(); |
| | | }; |
| | | } |
| | | if (lambda.getImplMethodKind() == 5 && lambda.getFunctionalInterfaceClass().equals("com/baomidou/mybatisplus/core/toolkit/support/SFunction") && lambda.getFunctionalInterfaceMethodName().equals("apply") && lambda.getFunctionalInterfaceMethodSignature().equals("(Ljava/lang/Object;)Ljava/lang/Object;") && lambda.getImplClass().equals("org/springblade/modules/notify/entity/BusinessNotify") && lambda.getImplMethodSignature().equals("()Ljava/lang/Long;")) { |
| | | return (v0) -> { |
| | | return v0.getNotifyId(); |
| | | }; |
| | | } |
| | | break; |
| | | case true: |
| | | if (lambda.getImplMethodKind() == 5 && lambda.getFunctionalInterfaceClass().equals("com/baomidou/mybatisplus/core/toolkit/support/SFunction") && lambda.getFunctionalInterfaceMethodName().equals("apply") && lambda.getFunctionalInterfaceMethodSignature().equals("(Ljava/lang/Object;)Ljava/lang/Object;") && lambda.getImplClass().equals("org/springblade/modules/notify/entity/NotifyConfigEntity") && lambda.getImplMethodSignature().equals("()Ljava/lang/String;")) { |
| | | return (v0) -> { |
| | | return v0.getType(); |
| | | }; |
| | | } |
| | | if (lambda.getImplMethodKind() == 5 && lambda.getFunctionalInterfaceClass().equals("com/baomidou/mybatisplus/core/toolkit/support/SFunction") && lambda.getFunctionalInterfaceMethodName().equals("apply") && lambda.getFunctionalInterfaceMethodSignature().equals("(Ljava/lang/Object;)Ljava/lang/Object;") && lambda.getImplClass().equals("org/springblade/modules/notify/entity/NotifyConfigEntity") && lambda.getImplMethodSignature().equals("()Ljava/lang/String;")) { |
| | | return (v0) -> { |
| | | return v0.getType(); |
| | | }; |
| | | } |
| | | if (lambda.getImplMethodKind() == 5 && lambda.getFunctionalInterfaceClass().equals("com/baomidou/mybatisplus/core/toolkit/support/SFunction") && lambda.getFunctionalInterfaceMethodName().equals("apply") && lambda.getFunctionalInterfaceMethodSignature().equals("(Ljava/lang/Object;)Ljava/lang/Object;") && lambda.getImplClass().equals("org/springblade/modules/notify/entity/NotifyConfigEntity") && lambda.getImplMethodSignature().equals("()Ljava/lang/String;")) { |
| | | return (v0) -> { |
| | | return v0.getType(); |
| | | }; |
| | | } |
| | | if (lambda.getImplMethodKind() == 5 && lambda.getFunctionalInterfaceClass().equals("com/baomidou/mybatisplus/core/toolkit/support/SFunction") && lambda.getFunctionalInterfaceMethodName().equals("apply") && lambda.getFunctionalInterfaceMethodSignature().equals("(Ljava/lang/Object;)Ljava/lang/Object;") && lambda.getImplClass().equals("org/springblade/modules/notify/entity/NotifyConfigEntity") && lambda.getImplMethodSignature().equals("()Ljava/lang/String;")) { |
| | | return (v0) -> { |
| | | return v0.getType(); |
| | | }; |
| | | } |
| | | if (lambda.getImplMethodKind() == 5 && lambda.getFunctionalInterfaceClass().equals("com/baomidou/mybatisplus/core/toolkit/support/SFunction") && lambda.getFunctionalInterfaceMethodName().equals("apply") && lambda.getFunctionalInterfaceMethodSignature().equals("(Ljava/lang/Object;)Ljava/lang/Object;") && lambda.getImplClass().equals("org/springblade/modules/notify/entity/NotifyConfigEntity") && lambda.getImplMethodSignature().equals("()Ljava/lang/String;")) { |
| | | return (v0) -> { |
| | | return v0.getType(); |
| | | }; |
| | | } |
| | | break; |
| | | case true: |
| | | if (lambda.getImplMethodKind() == 5 && lambda.getFunctionalInterfaceClass().equals("com/baomidou/mybatisplus/core/toolkit/support/SFunction") && lambda.getFunctionalInterfaceMethodName().equals("apply") && lambda.getFunctionalInterfaceMethodSignature().equals("(Ljava/lang/Object;)Ljava/lang/Object;") && lambda.getImplClass().equals("org/springblade/modules/notify/entity/BusinessNotify") && lambda.getImplMethodSignature().equals("()Ljava/lang/String;")) { |
| | | return (v0) -> { |
| | | return v0.getNotifyType(); |
| | | }; |
| | | } |
| | | break; |
| | | case true: |
| | | if (lambda.getImplMethodKind() == 5 && lambda.getFunctionalInterfaceClass().equals("com/baomidou/mybatisplus/core/toolkit/support/SFunction") && lambda.getFunctionalInterfaceMethodName().equals("apply") && lambda.getFunctionalInterfaceMethodSignature().equals("(Ljava/lang/Object;)Ljava/lang/Object;") && lambda.getImplClass().equals("org/springblade/core/mp/base/BaseEntity") && lambda.getImplMethodSignature().equals("()Ljava/lang/Long;")) { |
| | | return (v0) -> { |
| | | return v0.getId(); |
| | | }; |
| | | } |
| | | if (lambda.getImplMethodKind() == 5 && lambda.getFunctionalInterfaceClass().equals("com/baomidou/mybatisplus/core/toolkit/support/SFunction") && lambda.getFunctionalInterfaceMethodName().equals("apply") && lambda.getFunctionalInterfaceMethodSignature().equals("(Ljava/lang/Object;)Ljava/lang/Object;") && lambda.getImplClass().equals("org/springblade/core/mp/base/BaseEntity") && lambda.getImplMethodSignature().equals("()Ljava/lang/Long;")) { |
| | | return (v0) -> { |
| | | return v0.getId(); |
| | | }; |
| | | } |
| | | break; |
| | | case true: |
| | | if (lambda.getImplMethodKind() == 5 && lambda.getFunctionalInterfaceClass().equals("com/baomidou/mybatisplus/core/toolkit/support/SFunction") && lambda.getFunctionalInterfaceMethodName().equals("apply") && lambda.getFunctionalInterfaceMethodSignature().equals("(Ljava/lang/Object;)Ljava/lang/Object;") && lambda.getImplClass().equals("org/springblade/core/mp/base/BaseEntity") && lambda.getImplMethodSignature().equals("()Ljava/lang/Integer;")) { |
| | | return (v0) -> { |
| | | return v0.getStatus(); |
| | | }; |
| | | } |
| | | if (lambda.getImplMethodKind() == 5 && lambda.getFunctionalInterfaceClass().equals("com/baomidou/mybatisplus/core/toolkit/support/SFunction") && lambda.getFunctionalInterfaceMethodName().equals("apply") && lambda.getFunctionalInterfaceMethodSignature().equals("(Ljava/lang/Object;)Ljava/lang/Object;") && lambda.getImplClass().equals("org/springblade/core/mp/base/BaseEntity") && lambda.getImplMethodSignature().equals("()Ljava/lang/Integer;")) { |
| | | return (v0) -> { |
| | | return v0.getStatus(); |
| | | }; |
| | | } |
| | | if (lambda.getImplMethodKind() == 5 && lambda.getFunctionalInterfaceClass().equals("com/baomidou/mybatisplus/core/toolkit/support/SFunction") && lambda.getFunctionalInterfaceMethodName().equals("apply") && lambda.getFunctionalInterfaceMethodSignature().equals("(Ljava/lang/Object;)Ljava/lang/Object;") && lambda.getImplClass().equals("org/springblade/core/mp/base/BaseEntity") && lambda.getImplMethodSignature().equals("()Ljava/lang/Integer;")) { |
| | | return (v0) -> { |
| | | return v0.getStatus(); |
| | | }; |
| | | } |
| | | break; |
| | | } |
| | | throw new IllegalArgumentException("Invalid lambda deserialization"); |
| | | } |
| | | |
| | | public NotifyConfigServiceImpl(BusinessNotifyMapper notifyBusinessMapper, List<NotifierProvider> providers, @Lazy DingTalkApi dingTalkApi, @Lazy IOuterAppConfigService outerAppConfigService) { |
| | | this.notifyBusinessMapper = notifyBusinessMapper; |
| | |
| | | this.outerAppConfigService = outerAppConfigService; |
| | | } |
| | | |
| | | @Override // org.springblade.modules.notify.service.INotifyConfigService |
| | | |
| | | public void updateServerConfig(OuterAppConfig outerAppConfig) { |
| | | Integer appType = outerAppConfig.getAppType(); |
| | | if (appType.intValue() == 1) { |
| | |
| | | data.put("agentid", agentid); |
| | | data.put("corpid", corpid); |
| | | data.put("corpsecret", corpsecret); |
| | | NotifyConfigEntity config = getOne(Wrappers.<NotifyConfigEntity>lambdaQuery() |
| | | .eq(NotifyConfigEntity::getStatus, 1).eq(NotifyConfigEntity::getType, DefaultNotifyType.weiXinQY.name())); |
| | | /* |
| | | NotifyConfigEntity config = (NotifyConfigEntity) getOne((Wrapper) ((LambdaQueryWrapper) Wrappers.lambdaQuery().eq((v0) -> { |
| | | return v0.getStatus(); |
| | | }, 1)).eq((v0) -> { |
| | | return v0.getType(); |
| | | }, DefaultNotifyType.weiXinQY.name())); |
| | | }, DefaultNotifyType.weiXinQY.name()));*/ |
| | | if (config == null) { |
| | | config = new NotifyConfigEntity(); |
| | | config.setName(DefaultNotifyType.weiXinQY.getName()); |
| | |
| | | Map<String, Object> data2 = new HashMap<>(); |
| | | data2.put("appKey", appKey); |
| | | data2.put("appSecret", appSecret); |
| | | NotifyConfigEntity config2 = getOne(Wrappers.<NotifyConfigEntity>lambdaQuery().eq(NotifyConfigEntity::getStatus, 1) |
| | | .eq(NotifyConfigEntity::getType, DefaultNotifyType.dingTalk.name())); |
| | | /* |
| | | NotifyConfigEntity config2 = (NotifyConfigEntity) getOne((Wrapper) ((LambdaQueryWrapper) Wrappers.lambdaQuery().eq((v0) -> { |
| | | return v0.getStatus(); |
| | | }, 1)).eq((v0) -> { |
| | | return v0.getType(); |
| | | }, DefaultNotifyType.dingTalk.name())); |
| | | }, DefaultNotifyType.dingTalk.name()));*/ |
| | | if (config2 == null) { |
| | | config2 = new NotifyConfigEntity(); |
| | | config2.setName(DefaultNotifyType.dingTalk.getName()); |
| | |
| | | if (Func.equals(notifyType, DefaultNotifyType.dingTalk.name())) { |
| | | OuterAppConfig outerAppConfigDing = this.outerAppConfigService.getAppConfig(OuterAppConfigConstant.DING); |
| | | if (Func.isNotEmpty(outerAppConfigDing) && outerAppConfigDing.getStatus().equals(CommonConstant.ENABLE)) { |
| | | NotifyConfigEntity config = getOne(Wrappers.<NotifyConfigEntity>lambdaQuery() |
| | | .eq(NotifyConfigEntity::getType, DefaultNotifyType.dingTalk.name()).eq(NotifyConfigEntity::getStatus, 1)); |
| | | /* |
| | | NotifyConfigEntity config = (NotifyConfigEntity) getOne((Wrapper) ((LambdaQueryWrapper) Wrappers.lambdaQuery().eq((v0) -> { |
| | | return v0.getType(); |
| | | }, DefaultNotifyType.dingTalk.name())).eq((v0) -> { |
| | | return v0.getStatus(); |
| | | }, 1)); |
| | | }, 1));*/ |
| | | Map<String, Object> configuration = config.getConfiguration(); |
| | | if (!configuration.containsKey("appKey") || !configuration.containsKey("appSecret")) { |
| | | updateServerConfig(outerAppConfigDing); |
| | |
| | | return false; |
| | | } |
| | | |
| | | @Override // org.springblade.modules.notify.service.INotifyConfigService |
| | | |
| | | public NotifyConfigEntity saveOrUpdateConfig(NotifyConfigEntity notificationConfig) { |
| | | if (Func.isNotEmpty(notificationConfig.getId())) { |
| | | CacheUtil.evict("blade:notify", "notifier:id:", notificationConfig.getId(), false); |
| | | } |
| | | long count = count(Wrappers.<NotifyConfigEntity>lambdaQuery() |
| | | .ne(Func.isNotEmpty(notificationConfig.getId()), NotifyConfigEntity::getId, notificationConfig.getId()) |
| | | .eq(NotifyConfigEntity::getType, notificationConfig.getType())); |
| | | /* |
| | | long count = count((Wrapper) Wrappers.lambdaQuery().ne(Func.isNotEmpty(notificationConfig.getId()), (v0) -> { |
| | | return v0.getId(); |
| | | }, notificationConfig.getId()).eq((v0) -> { |
| | | return v0.getType(); |
| | | }, notificationConfig.getType())); |
| | | }, notificationConfig.getType()));*/ |
| | | if (count > 0) { |
| | | throw new ServiceException(MessageUtils.message("notify.service.config.not.be.repeated", new Object[0])); |
| | | } |
| | |
| | | return notificationConfig; |
| | | } |
| | | |
| | | @Override // org.springblade.modules.notify.service.INotifyConfigService |
| | | |
| | | public boolean checkUsedByBusinessNotify(String id) { |
| | | Long count = this.notifyBusinessMapper.selectCount(Wrappers.<BusinessNotify>lambdaQuery() |
| | | .eq(BusinessNotify::getNotifyId, id)); |
| | | /* |
| | | Long count = this.notifyBusinessMapper.selectCount((Wrapper) Wrappers.lambdaQuery().eq((v0) -> { |
| | | return v0.getNotifyId(); |
| | | }, id)); |
| | | }, id));*/ |
| | | if (count.longValue() > 0) { |
| | | throw new ServiceException(MessageUtils.message("notify.service.config.not.delete", new Object[0])); |
| | | } |
| | |
| | | } |
| | | |
| | | public Map<String, NotifyTypeInfo> getNotifyInfo() { |
| | | return (Map) getAllNotifyType().stream().filter(n -> { |
| | | return getAllNotifyType().stream().filter(n -> { |
| | | return ("weiXinMini".equals(n.getId()) || "weiXinMp".equals(n.getId())) ? false : true; |
| | | }).collect(Collectors.toMap((v0) -> { |
| | | return v0.getId(); |
| | |
| | | })); |
| | | } |
| | | |
| | | @Override // org.springblade.modules.notify.service.INotifyConfigService |
| | | |
| | | public List<NotifyTypeInfo> getServiceList() { |
| | | Map<String, NotifyTypeInfo> typeInfoMap = getNotifyInfo(); |
| | | List<String> typeList = CollectionUtil.list(Boolean.FALSE.booleanValue(), typeInfoMap.keySet()); |
| | | Map<String, NotifyConfigEntity> configMap = getConfigs(typeList); |
| | | List<BusinessNotify> businessNotifies = this.notifyBusinessMapper.selectList(Wrappers.<BusinessNotify>lambdaQuery().in(BusinessNotify::getNotifyType, typeList)); |
| | | /* |
| | | List<BusinessNotify> businessNotifies = this.notifyBusinessMapper.selectList((Wrapper) Wrappers.lambdaQuery().in((v0) -> { |
| | | return v0.getNotifyType(); |
| | | }, typeList)); |
| | | Map<String, List<BusinessNotify>> notifyMap = (Map) businessNotifies.stream().collect(Collectors.groupingBy((v0) -> { |
| | | }, typeList));*/ |
| | | Map<String, List<BusinessNotify>> notifyMap = businessNotifies.stream().collect(Collectors.groupingBy((v0) -> { |
| | | return v0.getNotifyType(); |
| | | })); |
| | | typeInfoMap.forEach(typeId, typeInfo -> { |
| | | typeInfoMap.forEach((typeId, typeInfo) -> { |
| | | if (configMap.containsKey(typeId)) { |
| | | NotifyConfigEntity config = (NotifyConfigEntity) configMap.get(typeId); |
| | | typeInfo.setConfigEntity(config); |
| | |
| | | } |
| | | typeInfo.setIsBindBusiness(Boolean.valueOf(notifyMap.containsKey(typeId))); |
| | | }); |
| | | return new ArrayList(typeInfoMap.values()); |
| | | return new ArrayList<>(typeInfoMap.values()); |
| | | } |
| | | |
| | | @Override // org.springblade.modules.notify.service.INotifyConfigService |
| | | |
| | | public ConfigMetadata getMetadataByTypeAndProvider(String type, String provider) { |
| | | ConfigMetadata result = null; |
| | | List<NotifierProvider> providerList = (List) this.providers.stream().filter(prov -> { |
| | | List<NotifierProvider> providerList = this.providers.stream().filter(prov -> { |
| | | return prov.getType().getId().equalsIgnoreCase(type) && prov.getProvider().getId().equalsIgnoreCase(provider); |
| | | }).collect(Collectors.toList()); |
| | | if (Func.isNotEmpty(providerList)) { |
| | |
| | | if (!type.equals(NotifyConstant.SMS_TYPE_VALUE)) { |
| | | return; |
| | | } |
| | | NotifyConfigEntity configEntity = (NotifyConfigEntity) getOne((Wrapper) Wrappers.lambdaQuery(NotifyConfigEntity.class).eq((v0) -> { |
| | | NotifyConfigEntity configEntity = (NotifyConfigEntity) getOne(Wrappers.lambdaQuery(NotifyConfigEntity.class).eq((v0) -> { |
| | | return v0.getId(); |
| | | }, notificationConfig.getId())); |
| | | if (ObjectUtil.isNull(configEntity)) { |
| | |
| | | } |
| | | |
| | | public Map<String, NotifyConfigEntity> getConfigs(List<String> types) { |
| | | List<NotifyConfigEntity> configList = list(Wrappers.<NotifyConfigEntity>lambdaQuery().in(NotifyConfigEntity::getType, types)); |
| | | /* |
| | | List<NotifyConfigEntity> configList = list((Wrapper) Wrappers.lambdaQuery().in((v0) -> { |
| | | return v0.getType(); |
| | | }, types)); |
| | | return (Map) configList.stream().collect(Collectors.toMap((v0) -> { |
| | | }, types));*/ |
| | | return configList.stream().collect(Collectors.toMap((v0) -> { |
| | | return v0.getType(); |
| | | }, notifyConfigEntity -> { |
| | | return notifyConfigEntity; |
| | | }, a, b -> { |
| | | }, (a, b) -> { |
| | | return a; |
| | | })); |
| | | } |
| | | |
| | | @Override // org.springblade.modules.notify.service.INotifyConfigService |
| | | |
| | | public List<NotifyTypeInfo> getAllNotifyType() { |
| | | List<NotifyTypeInfo> result = new ArrayList<>(); |
| | | Map<NotifyType, List<NotifierProvider>> groups = (Map) this.providers.stream().collect(Collectors.groupingBy((v0) -> { |
| | | Map<NotifyType, List<NotifierProvider>> groups = this.providers.stream().collect(Collectors.groupingBy((v0) -> { |
| | | return v0.getType(); |
| | | })); |
| | | groups.forEach(type, providerList -> { |
| | | groups.forEach((type, providerList) -> { |
| | | NotifyTypeInfo typeInfo = new NotifyTypeInfo(); |
| | | typeInfo.setId(type.getId()); |
| | | typeInfo.setName(type.getName()); |
| | | typeInfo.setProviderInfos((List) providerList.stream().map(ProviderInfo::of).collect(Collectors.toList())); |
| | | typeInfo.setProviderInfos(providerList.stream().map(ProviderInfo::of).collect(Collectors.toList())); |
| | | result.add(typeInfo); |
| | | }); |
| | | return result; |