public VersionedAssetItemIterator(NodeIterator nodes, RulesRepository repo, String[] dependencies) { super(nodes, repo); //this.dependencies = dependencies; for(String dependency : dependencies) { String[] decodedPath = ModuleItem.decodeDependencyPath(dependency); if(!"LATEST".equals(decodedPath[1])) { dependencyVersionMap.put(decodedPath[0], decodedPath[1]); } } }
public VersionedAssetItemIterator(NodeIterator nodes, RulesRepository repo, String[] dependencies) { super(nodes, repo); //this.dependencies = dependencies; for(String dependency : dependencies) { String[] decodedPath = ModuleItem.decodeDependencyPath(dependency); if(!"LATEST".equals(decodedPath[1])) { dependencyVersionMap.put(decodedPath[0], decodedPath[1]); } } }
public void updateDependency(String dependencyPath) { String[] existingDependencies = getStringPropertyArray(DEPENDENCIES_PROPERTY_NAME); boolean found = false; for (int i = 0; i < existingDependencies.length; i++) { if (decodeDependencyPath(existingDependencies[i])[0] .equals(decodeDependencyPath(dependencyPath)[0])) { found = true; existingDependencies[i] = dependencyPath; this.updateStringArrayProperty(existingDependencies, DEPENDENCIES_PROPERTY_NAME, false); break; } } if (!found) { String[] newDependencies = new String[existingDependencies.length + 1]; System.arraycopy(existingDependencies, 0, newDependencies, 0, existingDependencies.length); newDependencies[existingDependencies.length] = dependencyPath; this.updateStringArrayProperty(newDependencies, DEPENDENCIES_PROPERTY_NAME, false); } }
public void updateDependency(String dependencyPath) { String[] existingDependencies = getStringPropertyArray(DEPENDENCIES_PROPERTY_NAME); boolean found = false; for (int i = 0; i < existingDependencies.length; i++) { if (decodeDependencyPath(existingDependencies[i])[0] .equals(decodeDependencyPath(dependencyPath)[0])) { found = true; existingDependencies[i] = dependencyPath; this.updateStringArrayProperty(existingDependencies, DEPENDENCIES_PROPERTY_NAME, false); break; } } if (!found) { String[] newDependencies = new String[existingDependencies.length + 1]; System.arraycopy(existingDependencies, 0, newDependencies, 0, existingDependencies.length); newDependencies[existingDependencies.length] = dependencyPath; this.updateStringArrayProperty(newDependencies, DEPENDENCIES_PROPERTY_NAME, false); } }
String path = decodeDependencyPath(existingDependency)[0]; if (result.containsKey(path)) { result.put(path,
String path = decodeDependencyPath(existingDependency)[0]; if (result.containsKey(path)) { result.put(path,