public final class CurlyBracketsStructureCheck extends AbstractCheck
This is how a correct curly bracket structure should look like:
String[] array = new String[] { "first", "second" };or
String[] array = new String[] {"first", "second"};
The motivation for such formatting is simple - we want to see the entire block as fast as possible. When you look at a block of code you should be able to see where it starts and where it ends.
Constructor and Description |
---|
CurlyBracketsStructureCheck() |
Modifier and Type | Method and Description |
---|---|
int[] |
getDefaultTokens() |
void |
visitToken(DetailAST ast) |
beginTree, destroy, finishTree, getAcceptableTokens, getClassLoader, getFileContents, getLine, getLines, getRequiredTokens, getTabWidth, getTokenNames, init, isCommentNodesRequired, leaveToken, log, log, setClassLoader, setFileContents, setMessages, setTabWidth, setTokens
getCustomMessages, getId, getMessageBundle, getSeverity, getSeverityLevel, log, setId, setSeverity
configure, contextualize, finishLocalSetup, getConfiguration, setupChild
public int[] getDefaultTokens()
getDefaultTokens
in class AbstractCheck
public void visitToken(DetailAST ast)
visitToken
in class AbstractCheck
Copyright © 2011–2018 Qulice.com. All rights reserved.