Package org.apache.sysds.utils
Class ParameterBuilder
- java.lang.Object
-
- org.apache.sysds.utils.ParameterBuilder
-
public class ParameterBuilder extends Object
Class to help setting variables in a script.
-
-
Constructor Summary
Constructors Constructor Description ParameterBuilder()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
setVariablesInScript(String strScriptDirectory, String strScriptFile, HashMap<String,String> variables)
Replaces variables in a DML or R script with the specified values.static void
setVariablesInScript(String strScriptPathName, HashMap<String,String> variables)
Replaces variables in a DML or R script with the specified values.
-
-
-
Method Detail
-
setVariablesInScript
public static void setVariablesInScript(String strScriptPathName, HashMap<String,String> variables)
Replaces variables in a DML or R script with the specified values. A variable of format $$name$$ will be replaced where the name is used to identify the variable in the hashmap containing the belonging value.
- Parameters:
strScriptPathName
- filename of the DML scriptvariables
- hashmap containing all the variables and their replacements
-
setVariablesInScript
public static void setVariablesInScript(String strScriptDirectory, String strScriptFile, HashMap<String,String> variables)
Replaces variables in a DML or R script with the specified values. A variable of format $$name$$ will be replaced where the name is used to identify the variable in the hashmap containing the belonging value.
- Parameters:
strScriptDirectory
- directory which contains the DML scriptstrScriptFile
- filename of the DML scriptvariables
- hashmap containing all the variables and their replacements
-
-