Source:
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 { List<IRepositoryViewObject> all = ProxyRepositoryFactory.getInstance().getAll(ERepositoryObjectType.PROCESS); 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(); } } } } } }

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(); } } } } } }