Package com.igormaznitsa.jcp.context
Interface SpecialVariableProcessor
-
- All Known Implementing Classes:
EnvironmentVariableProcessor
,JCPSpecialVariableProcessor
,MavenPropertiesImporter
,PreprocessTask
public interface SpecialVariableProcessor
The interface describes a special variable processor which will be called for variables met by a preprocessor in expressions
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Value
getVariable(java.lang.String varName, PreprocessorContext context)
Get the value for the variablejava.lang.String[]
getVariableNames()
Get all variable names allowed by the processor as an array, all names must be in lower casevoid
setVariable(java.lang.String varName, Value value, PreprocessorContext context)
Set a value to the variable
-
-
-
Method Detail
-
getVariableNames
@MustNotContainNull java.lang.String[] getVariableNames()
Get all variable names allowed by the processor as an array, all names must be in lower case- Returns:
- allowed variable names as a String array
-
getVariable
Value getVariable(java.lang.String varName, PreprocessorContext context)
Get the value for the variable- Parameters:
varName
- the variable name, must not be nullcontext
- the preprocessor context, it can be null- Returns:
- the value, it must not return null because it will notified preprocessor that it supports the variable
-
setVariable
void setVariable(java.lang.String varName, Value value, PreprocessorContext context)
Set a value to the variable- Parameters:
varName
- 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
-
-