public class RequiredRegexpCheck extends AbstractFormatCheck
A check that makes sure that a specified pattern exists in the code.
An example of how to configure the check to make sure a copyright statement is included in the file (but without requirements on where in the file it should be):
<module name="RequiredRegexp">
<property name="format" value="This code is copyrighted"/>
</module>
| Constructor and Description |
|---|
RequiredRegexpCheck()
Instantiates an new GenericIllegalRegexpCheck.
|
| Modifier and Type | Method and Description |
|---|---|
void |
beginTree(DetailAST aRootAST)
Called before the starting to process a tree.
|
int[] |
getDefaultTokens()
Returns the default token a check is interested in.
|
getFormat, getRegexp, setCompileFlags, setFormatdestroy, finishTree, getAcceptableTokens, getClassLoader, getFileContents, getLines, getRequiredTokens, getTabWidth, getTokenNames, init, leaveToken, log, log, setClassLoader, setFileContents, setMessages, setTabWidth, setTokens, visitTokengetId, getMessageBundle, getSeverity, getSeverityLevel, log, log, log, log, log, log, log, log, log, setId, setSeverityconfigure, contextualize, finishLocalSetup, getConfiguration, setupChildpublic RequiredRegexpCheck()
public int[] getDefaultTokens()
getDefaultTokens in class CheckTokenTypes