Package org.codehaus.mojo.buildhelper
Class RegexPropertyMojo
- java.lang.Object
-
- org.apache.maven.plugin.AbstractMojo
-
- org.codehaus.mojo.buildhelper.AbstractDefinePropertyMojo
-
- org.codehaus.mojo.buildhelper.AbstractRegexPropertyMojo
-
- org.codehaus.mojo.buildhelper.RegexPropertyMojo
-
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled,org.apache.maven.plugin.Mojo
@Mojo(name="regex-property", defaultPhase=VALIDATE, threadSafe=true) public class RegexPropertyMojo extends AbstractRegexPropertyMojoSets a property by applying a regex replacement rule to a supplied value.- Since:
- 1.7
-
-
Field Summary
Fields Modifier and Type Field Description private booleanfailIfNoMatchWhether to fail if no match is found.private java.lang.StringnameThe property to set.private java.lang.StringregexThe regex to replace.private java.lang.StringreplacementThe replacement.private java.lang.StringvalueThe pre-transformation value.
-
Constructor Summary
Constructors Constructor Description RegexPropertyMojo()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidexecute()-
Methods inherited from class org.codehaus.mojo.buildhelper.AbstractRegexPropertyMojo
execute
-
Methods inherited from class org.codehaus.mojo.buildhelper.AbstractDefinePropertyMojo
defineProperty, getProject
-
-
-
-
Field Detail
-
name
@Parameter(required=true) private java.lang.String name
The property to set.
-
value
@Parameter(required=true) private java.lang.String value
The pre-transformation value.
-
regex
@Parameter(required=true) private java.lang.String regex
The regex to replace.
-
replacement
@Parameter(defaultValue="") private java.lang.String replacement
The replacement.
-
failIfNoMatch
@Parameter(defaultValue="true") private boolean failIfNoMatch
Whether to fail if no match is found.
-
-