package org.gcube.dataanalysis.dataminer.poolmanager.util; import org.gcube.dataanalysis.dataminer.poolmanager.datamodel.Algorithm; import org.gcube.dataanalysis.dataminer.poolmanager.process.AlgorithmPackageParser; ***REMOVED*** /** * Created by ggiammat on 5/9/17. */ public class AlgorithmBuilder { public static Algorithm create(String algorithmPackageURL) throws IOException, InterruptedException { return create(algorithmPackageURL, null, null, null, null, null, null, null); ***REMOVED*** public static Algorithm create(String algorithmPackageURL, String vre, String hostname, String name, String description, String category, String algorithmType, String skipJava) throws IOException, InterruptedException { Algorithm algo = new AlgorithmPackageParser().parsePackage(algorithmPackageURL); if(category != null){ algo.setCategory(category); ***REMOVED*** ***REMOVED***FIXME: do the same done for category if (algo.getAlgorithmType() == null) { algo.setAlgorithmType(algorithmType); ***REMOVED*** else algo.setAlgorithmType(algo.getCategory()); if (algo.getSkipJava() == null) { algo.setSkipJava(skipJava); ***REMOVED*** else algo.setSkipJava(algo.getSkipJava()); if (algo.getName() == null) { algo.setName(name); ***REMOVED*** else algo.setName(algo.getName()); if (algo.getDescription() == null) { algo.setDescription(description); ; ***REMOVED*** else algo.setDescription(algo.getDescription()); return algo; ***REMOVED*** ***REMOVED***