public abstract class AbstractPropertyEnforcerRule extends AbstractNonCacheableEnforcerRule
| Modifier and Type | Field and Description |
|---|---|
String |
regex
Deprecated.
the visibility will be reduced to private with the next major version
|
String |
regexMessage
Deprecated.
the visibility will be reduced to private with the next major version
|
message| Constructor and Description |
|---|
AbstractPropertyEnforcerRule() |
| Modifier and Type | Method and Description |
|---|---|
void |
execute(org.apache.maven.enforcer.rule.api.EnforcerRuleHelper helper)
Execute the rule.
|
abstract String |
getName()
How the property that is being evaluated is called
|
abstract String |
getPropertyName()
The name of the property currently being evaluated, this is used for default message pourpouses only
|
String |
getRegex()
Get the property value to a given regular expression.
|
String |
getRegexMessage()
Get a warning message if the regular expression is not matched.
|
abstract Object |
resolveValue(org.apache.maven.enforcer.rule.api.EnforcerRuleHelper helper)
Resolves the property value
|
void |
setRegex(String regex)
Set the property value to a given regular expression.
|
void |
setRegexMessage(String regexMessage)
Set a warning message if the regular expression is not matched.
|
getCacheId, isCacheable, isResultValidgetMessage, setMessagepublic String regex
null (any value is ok).#setRegex(String)},
#getRegex()}public String regexMessage
#setRegexMessage(String)},
#getRegexMessage()}public final void setRegex(String regex)
null (any value is ok).the - regular expressionpublic final String getRegex()
null (any value is ok).public final void setRegexMessage(String regexMessage)
regexMessage - the regex messagepublic final String getRegexMessage()
public void execute(org.apache.maven.enforcer.rule.api.EnforcerRuleHelper helper)
throws org.apache.maven.enforcer.rule.api.EnforcerRuleException
helper - the helperorg.apache.maven.enforcer.rule.api.EnforcerRuleException - the enforcer rule exceptionpublic abstract String getName()
public abstract String getPropertyName()
public abstract Object resolveValue(org.apache.maven.enforcer.rule.api.EnforcerRuleHelper helper) throws org.apache.maven.enforcer.rule.api.EnforcerRuleException
helper - org.apache.maven.enforcer.rule.api.EnforcerRuleExceptionCopyright © 2007-2014 The Apache Software Foundation. All Rights Reserved.