AbstractCheck
instead.@Deprecated public abstract class AbstractComplexityCheck extends AbstractCheck
Modifier | Constructor and Description |
---|---|
protected |
AbstractComplexityCheck(int max)
Deprecated.
Creates an instance.
|
Modifier and Type | Method and Description |
---|---|
protected BigInteger |
getCurrentValue()
Deprecated.
Gets the current value.
|
protected abstract String |
getMessageID()
Deprecated.
Gets the message ID to log violations with.
|
int[] |
getRequiredTokens()
Deprecated.
The tokens that this check must be registered for.
|
protected void |
incrementCurrentValue(BigInteger amount)
Deprecated.
Increments the current value by a specified amount.
|
void |
leaveToken(DetailAST ast)
Deprecated.
Called after all the child nodes have been process.
|
protected abstract void |
leaveTokenHook(DetailAST ast)
Deprecated.
Hook called when leaving a token.
|
protected BigInteger |
popValue()
Deprecated.
Pops a value off the stack and makes it the current value.
|
protected void |
pushValue()
Deprecated.
Push the current value on the stack.
|
protected void |
setCurrentValue(BigInteger value)
Deprecated.
Set the current value.
|
void |
setMax(int max)
Deprecated.
Set the maximum threshold allowed.
|
void |
visitToken(DetailAST ast)
Deprecated.
Called to process a token.
|
protected abstract void |
visitTokenHook(DetailAST ast)
Deprecated.
Hook called when visiting a token.
|
beginTree, destroy, finishTree, getAcceptableTokens, getClassLoader, getDefaultTokens, getFileContents, getLine, getLines, getTabWidth, getTokenNames, init, isCommentNodesRequired, log, log, setClassLoader, setFileContents, setMessages, setTabWidth, setTokens
getCustomMessages, getId, getMessageBundle, getSeverity, getSeverityLevel, log, setId, setSeverity
configure, contextualize, finishLocalSetup, getConfiguration, setupChild
protected AbstractComplexityCheck(int max)
max
- the threshold of when to report an errorprotected abstract String getMessageID()
protected abstract void visitTokenHook(DetailAST ast)
ast
- the token being visitedprotected abstract void leaveTokenHook(DetailAST ast)
ast
- the token being leftpublic final int[] getRequiredTokens()
AbstractCheck
getRequiredTokens
in class AbstractCheck
TokenTypes
public final void setMax(int max)
max
- the maximum thresholdpublic void visitToken(DetailAST ast)
AbstractCheck
visitToken
in class AbstractCheck
ast
- the token to processpublic void leaveToken(DetailAST ast)
AbstractCheck
leaveToken
in class AbstractCheck
ast
- the token leavingprotected final BigInteger getCurrentValue()
protected final void setCurrentValue(BigInteger value)
value
- the new valueprotected final void incrementCurrentValue(BigInteger amount)
amount
- the amount to increment byprotected final void pushValue()
protected final BigInteger popValue()
Copyright © 2001-2017. All Rights Reserved.