public class EnvironmentVariableProcessor extends java.lang.Object implements SpecialVariableProcessor
| Modifier and Type | Field and Description |
|---|---|
private java.util.Map<java.lang.String,Value> |
environmentVars |
private static java.lang.String |
PREFIX |
| Constructor and Description |
|---|
EnvironmentVariableProcessor() |
| Modifier and Type | Method and Description |
|---|---|
Value |
getVariable(java.lang.String varName,
PreprocessorContext context)
Get the value for the variable
|
java.lang.String[] |
getVariableNames()
Get all variable names allowed by the processor as an array, all names must
be in lower case
|
void |
setVariable(java.lang.String varName,
Value value,
PreprocessorContext context)
Set a value to the variable
|
private static final java.lang.String PREFIX
private final java.util.Map<java.lang.String,Value> environmentVars
public java.lang.String[] getVariableNames()
SpecialVariableProcessorgetVariableNames in interface SpecialVariableProcessorpublic Value getVariable(java.lang.String varName, PreprocessorContext context)
SpecialVariableProcessorgetVariable in interface SpecialVariableProcessorvarName - the variable name, must not be nullcontext - the preprocessor context, it can be nullpublic void setVariable(java.lang.String varName,
Value value,
PreprocessorContext context)
SpecialVariableProcessorsetVariable in interface SpecialVariableProcessorvarName - the variable name, must not be nullvalue - the value to be set to the variable, must not be nullcontext - the preprocessor context, it can be null