Class AbstractMavenFilteringRequest
java.lang.Object
org.apache.maven.shared.filtering.AbstractMavenFilteringRequest
- Direct Known Subclasses:
MavenFileFilterRequest,MavenReaderFilterRequest,MavenResourcesExecution
- Since:
- 1.0-beta-3
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate Propertiesprivate LinkedHashSet<String> Set of expression delimiter specifications to use during filtering.private StringString which will escape interpolation mechanism: foo \${foo.bar} -> foo ${foo.bar}private booleanprivate booleanprivate org.apache.maven.project.MavenProjectprivate org.apache.maven.execution.MavenSessionList of Strings considered as expressions which contains values in the project/pom: pom project Default value will be pom and project.private booleanDo not stop trying to filter tokens when reaching EOL. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedCreate instance.protectedAbstractMavenFilteringRequest(org.apache.maven.project.MavenProject mavenProject, List<String> filters, org.apache.maven.execution.MavenSession mavenSession) Create instance with given parameters -
Method Summary
Modifier and TypeMethodDescriptionSeedelimitersfor more information and default values.Alias forgetFilters().The list of filters.org.apache.maven.project.MavenProjectorg.apache.maven.execution.MavenSessionprivate voidbooleanAlias forisEscapeWindowsPaths()booleanbooleanbooleanvoidsetAdditionalProperties(Properties additionalProperties) voidsetDelimiters(LinkedHashSet<String> delimiters) Set the delimiter specifications to use during filtering.voidsetDelimiters(LinkedHashSet<String> delimiters, boolean useDefaultDelimiters) voidsetEscapedBackslashesInFilePath(boolean escape) Alias forsetEscapeWindowsPaths(boolean)voidsetEscapeString(String escapeString) voidsetEscapeWindowsPaths(boolean escapedBackslashesInFilePath) voidsetFileFilters(List<String> paramfilters) Alias forsetFilters(List)voidsetFilters(List<String> filters) Set the filters.voidsetInjectProjectBuildFilters(boolean injectProjectBuildFilters) voidsetMavenProject(org.apache.maven.project.MavenProject mavenProject) Set the MavenProject.voidsetMavenSession(org.apache.maven.execution.MavenSession mavenSession) voidsetProjectStartExpressions(List<String> projectStartExpressions) voidsetSupportMultiLineFiltering(boolean supportMultiLineFiltering)
-
Field Details
-
mavenProject
private org.apache.maven.project.MavenProject mavenProject -
filters
-
escapeWindowsPaths
private boolean escapeWindowsPaths -
mavenSession
private org.apache.maven.execution.MavenSession mavenSession -
projectStartExpressions
List of Strings considered as expressions which contains values in the project/pom: pom project Default value will be pom and project.- Since:
- 1.0-beta-2
-
escapeString
String which will escape interpolation mechanism: foo \${foo.bar} -> foo ${foo.bar}- Since:
- 1.0-beta-2
-
additionalProperties
- Since:
- 1.0-beta-3
-
injectProjectBuildFilters
private boolean injectProjectBuildFilters- Since:
- 1.0-beta-3
-
delimiters
Set of expression delimiter specifications to use during filtering. Delimiter specifications are given in the form 'BEGIN*END' or, for symmetrical delimiters, simply 'TOKEN'. The default values are '${*}' and '@'.- Since:
- 1.0-beta-3
-
supportMultiLineFiltering
private boolean supportMultiLineFilteringDo not stop trying to filter tokens when reaching EOL.- Since:
- 1.0
-
-
Constructor Details
-
AbstractMavenFilteringRequest
protected AbstractMavenFilteringRequest()Create instance. -
AbstractMavenFilteringRequest
protected AbstractMavenFilteringRequest(org.apache.maven.project.MavenProject mavenProject, List<String> filters, org.apache.maven.execution.MavenSession mavenSession) Create instance with given parameters- Parameters:
mavenProject- The instance of MavenProject.filters- The list of filters.mavenSession- The MavenSession.
-
-
Method Details
-
initDefaults
private void initDefaults() -
getMavenProject
public org.apache.maven.project.MavenProject getMavenProject()- Returns:
- The MavenProject
-
setMavenProject
public void setMavenProject(org.apache.maven.project.MavenProject mavenProject) Set the MavenProject.- Parameters:
mavenProject- The MavenProject to be set.
-
getFilters
The list of filters.- Returns:
- The list of currently set filters.
-
setFilters
Set the filters.- Parameters:
filters- Set the list of filters
-
getFileFilters
Alias forgetFilters().- Returns:
- The list of filters.
-
setFileFilters
Alias forsetFilters(List)- Parameters:
paramfilters- The list of filters to be set.
-
isEscapeWindowsPaths
public boolean isEscapeWindowsPaths()- Returns:
- true if escape is activated false otherwise.
- Since:
- 1.0-beta-3
-
setEscapeWindowsPaths
public void setEscapeWindowsPaths(boolean escapedBackslashesInFilePath) - Parameters:
escapedBackslashesInFilePath- true or false.- Since:
- 1.0-beta-3
-
isEscapedBackslashesInFilePath
public boolean isEscapedBackslashesInFilePath()Alias forisEscapeWindowsPaths()- Returns:
- The current value of
isEscapeWindowsPaths()
-
setEscapedBackslashesInFilePath
public void setEscapedBackslashesInFilePath(boolean escape) Alias forsetEscapeWindowsPaths(boolean)- Parameters:
escape- activate or deactivate escaping.
-
getMavenSession
public org.apache.maven.execution.MavenSession getMavenSession()- Returns:
- Current value of mavenSession
-
setMavenSession
public void setMavenSession(org.apache.maven.execution.MavenSession mavenSession) - Parameters:
mavenSession- Set new value for the MavenSession of the instance.
-
getAdditionalProperties
- Returns:
- the additional properties.
- Since:
- 1.0-beta-3
-
setAdditionalProperties
- Parameters:
additionalProperties- The additional properties to be set.- Since:
- 1.0-beta-3
-
isInjectProjectBuildFilters
public boolean isInjectProjectBuildFilters()- Returns:
- the current value of injectProjectBuildFilters.
- Since:
- 1.0-beta-3
-
setInjectProjectBuildFilters
public void setInjectProjectBuildFilters(boolean injectProjectBuildFilters) - Parameters:
injectProjectBuildFilters- true or false.- Since:
- 1.0-beta-3
-
getEscapeString
- Returns:
- Current value of escapeString.
- Since:
- 1.0-beta-2
-
setEscapeString
- Parameters:
escapeString- The escape string to use- Since:
- 1.0-beta-2
-
getProjectStartExpressions
- Returns:
- The list of project start expressions.
- Since:
- 1.0-beta-2
-
setProjectStartExpressions
- Parameters:
projectStartExpressions- The start expressions- Since:
- 1.0-beta-2
-
getDelimiters
Seedelimitersfor more information and default values.- Returns:
- Not allowed to be
nullor empty. - Since:
- 1.0-beta-3
-
setDelimiters
Set the delimiter specifications to use during filtering. Specifications should be of the form: 'BEGIN*END' for asymmetrical delimiters, or 'TOKEN' for symmetrical delimiters. Seedelimitersfor more information and default values.- Parameters:
delimiters- Ifnull, reset delimiters to '${*}' only. Otherwise, use the provided value.- Since:
- 1.0-beta-3
-
setDelimiters
- Parameters:
delimiters- Ifnullthan nothing will happen. If notnullthe delimiters will be set according to the contents. If delimiter entries arenullthose entries will be set to '${*}'.useDefaultDelimiters- true if the default delimiters will be used false otherwise.
-
isSupportMultiLineFiltering
public boolean isSupportMultiLineFiltering()- Returns:
- If support multiple line filtering is active or not.
-
setSupportMultiLineFiltering
public void setSupportMultiLineFiltering(boolean supportMultiLineFiltering) - Parameters:
supportMultiLineFiltering- activate or deactivate multiple line filtering support.
-