Source:
<code>private void checkMultipleTRunjobVersion() { if (getComponent() != null && "tRunJob".equals(getComponent().getName())) { List<? extends INode> allNodes = process.getGraphicalNodes(); IElementParameter thisElement = this.getElementParameter(EParameterName.PROCESS.getName()); Object thisVersion = thisElement.getChildParameters().get(EParameterName.PROCESS_TYPE_VERSION.getName()).getValue(); String lastVersion = null; try { <START> List<IRepositoryViewObject> all = ProxyRepositoryFactory.getInstance().getAll(ERepositoryObjectType.PROCESS); <END> for (IRepositoryViewObject obj : all) { if (obj.getLabel().equals(thisElement.getValue())) { lastVersion = obj.getVersion(); } } } catch (PersistenceException e) { CommonExceptionHandler.process(e); } if ("Latest".equals(thisVersion)) { thisVersion = lastVersion; } for (INode node : allNodes) { if (node instanceof Node && "tRunJob".equals(node.getComponent().getName())) { if (this.getUniqueName().equals(node.getUniqueName())) { continue; } IElementParameter element = node.getElementParameter(EParameterName.PROCESS.getName()); Object version = element.getChildParameters().get(EParameterName.PROCESS_TYPE_VERSION.getName()).getValue(); if ("Latest".equals(version)) { version = lastVersion; } if (thisElement.getValue().equals(element.getValue())) { if (!thisVersion.equals(version)) { Problems.add(ProblemStatus.ERROR, this, Messages.getString("Node.checkMultipleTRunjobVersion")); } else { Problems.clearAll((Node) node); Problems.refreshOneNodeStatus(node); Problems.refreshProblemTreeView(); } } } } } }</code><technical_language>Do ProxyRepositoryFactory#getLastVersion? Please ProxyRepositoryFactory#getLastVersion(Project project, String id, String folderPath, ERepositoryObjectType type), I need consider process types, please refer ERepositoryObjectType#getAllTypesOfProcess</technical_language>

Target:
private void checkMultipleTRunjobVersion() { if (getComponent() != null && "tRunJob".equals(getComponent().getName())) { List<? extends INode> allNodes = process.getGraphicalNodes(); IElementParameter thisElement = this.getElementParameter(EParameterName.PROCESS.getName()); if (StringUtils.isBlank(thisElement.getValue().toString())) { return; } Map<String, IElementParameter> childParameters = thisElement.getChildParameters(); Object thisVersion = childParameters.get(EParameterName.PROCESS_TYPE_VERSION.getName()).getValue(); String lastVersion = null; try { IRepositoryViewObject subprocess = null; for (ERepositoryObjectType type : ERepositoryObjectType.getAllTypesOfProcess()) { subprocess = ProxyRepositoryFactory.getInstance() .getLastVersion(childParameters.get(EParameterName.PROCESS_TYPE_PROCESS.getName()).getValue().toString(),"",type); if(subprocess!=null) { break; } } lastVersion = subprocess.getProperty().getVersion(); } catch (PersistenceException e) { CommonExceptionHandler.process(e); } if ("Latest".equals(thisVersion)) { thisVersion = lastVersion; } for (INode node : allNodes) { if (node instanceof Node && "tRunJob".equals(node.getComponent().getName())) { if (this.getUniqueName().equals(node.getUniqueName())) { continue; } IElementParameter element = node.getElementParameter(EParameterName.PROCESS.getName()); Object version = element.getChildParameters().get(EParameterName.PROCESS_TYPE_VERSION.getName()).getValue(); if ("Latest".equals(version)) { version = lastVersion; } if (thisElement.getValue().equals(element.getValue())) { if (!thisVersion.equals(version)) { Problems.add(ProblemStatus.ERROR, this, Messages.getString("Node.checkMultipleTRunjobVersion")); } else { Problems.clearAll((Node) node); Problems.refreshOneNodeStatus(node); Problems.refreshProblemTreeView(); } } } } } }