Source:
public static List<IComponent> filterUnifiedComponent(RepositoryComponentSetting setting, List<IComponent> componentList, String dbTypeName) { if (GlobalServiceRegister.getDefault().isServiceRegistered(IUnifiedComponentService.class)) { List<IComponent> filtedList = new ArrayList<IComponent>(); IUnifiedComponentService service = GlobalServiceRegister.getDefault().getService(IUnifiedComponentService.class); IComponentsHandler componentsHandler = ComponentsFactoryProvider.getInstance().getComponentsHandler(); Map<String, IComponent> componentMap = new HashMap<String, IComponent>(); for (IComponent component : componentList) { String databaseName = service.getUnifiedCompDisplayName(service.getDelegateComponent(component), component.getDisplayName()); if (StringUtils.isNotBlank(databaseName) && !databaseName.equals(dbTypeName)) { continue; } if (isAdditionalJDBC(databaseName)) { String compKey = StringUtils.deleteWhitespace(databaseName); if (component.getName().contains(compKey) && FILTER_DEFINITION.contains(component.getName().replaceFirst(compKey, "JDBC"))) { continue; } } filtedList.add(component); } for (IComponent component : componentList) { if (componentsHandler != null && componentsHandler.extractComponentsCategory() != null) { if (!component.getPaletteType().equals(componentsHandler.extractComponentsCategory().getName())) { continue; } } if (isAdditionalJDBC(dbTypeName) && FILTER_DEFINITION.contains(component.getName())) { continue; } IComponent delegateComponent = service.getDelegateComponent(component); if (delegateComponent != null) { if (!filtedList.contains(delegateComponent)) { filtedList.add(delegateComponent); } if (component.getName().equals(setting.getInputComponent())) { setting.setInputComponent(delegateComponent.getName()); } if (component.getName().equals(setting.getOutputComponent())) { setting.setOutputComponent(delegateComponent.getName()); } if (component.getName().equals(setting.getDefaultComponent())) { setting.setDefaultComponent(delegateComponent.getName()); } } else { filtedList.add(component); } } return filtedList; } return componentList; }

Target:
public static List<IComponent> filterUnifiedComponent(RepositoryComponentSetting setting, List<IComponent> componentList, String dbTypeName) { if (GlobalServiceRegister.getDefault().isServiceRegistered(IUnifiedComponentService.class)) { List<IComponent> filtedList = new ArrayList<IComponent>(); IUnifiedComponentService service = GlobalServiceRegister.getDefault().getService(IUnifiedComponentService.class); IComponentsHandler componentsHandler = ComponentsFactoryProvider.getInstance().getComponentsHandler(); Map<String, IComponent> componentMap = new HashMap<String, IComponent>(); for (IComponent component : componentList) { String databaseName = service.getUnifiedCompDisplayName(service.getDelegateComponent(component), component.getName()); if (StringUtils.isNotBlank(databaseName) && !databaseName.equals(dbTypeName)) { continue; } if (isAdditionalJDBC(databaseName)) { String compKey = StringUtils.deleteWhitespace(databaseName); if (component.getName().contains(compKey) && FILTER_DEFINITION.contains(component.getName().replaceFirst(compKey, "JDBC"))) { continue; } } filtedList.add(component); } for (IComponent component : componentList) { if (componentsHandler != null && componentsHandler.extractComponentsCategory() != null) { if (!component.getPaletteType().equals(componentsHandler.extractComponentsCategory().getName())) { continue; } } if (isAdditionalJDBC(dbTypeName) && FILTER_DEFINITION.contains(component.getName())) { continue; } IComponent delegateComponent = service.getDelegateComponent(component); if (delegateComponent != null) { if (!filtedList.contains(delegateComponent)) { filtedList.add(delegateComponent); } if (component.getName().equals(setting.getInputComponent())) { setting.setInputComponent(delegateComponent.getName()); } if (component.getName().equals(setting.getOutputComponent())) { setting.setOutputComponent(delegateComponent.getName()); } if (component.getName().equals(setting.getDefaultComponent())) { setting.setDefaultComponent(delegateComponent.getName()); } } else { filtedList.add(component); } } return filtedList; } return componentList; }