|
Groovy Documentation | |||||||
FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | PROPERTY | CONSTR | METHOD | DETAIL: FIELD | PROPERTY | CONSTR | METHOD |
java.lang.Objectorg.codenarc.rule.AbstractRule
org.codenarc.rule.AbstractAstVisitorRule
org.codenarc.rule.braces.ElseBlockBracesRule
class ElseBlockBracesRule extends AbstractAstVisitorRule
Rule that checks that else blocks use braces rather than a single statement.
By default, braces are not required for an else
if it is followed immediately
by an if
. Set the bracesRequiredForElseIf
property to true to
require braces is that situation as well.
Property Summary | |
---|---|
Class |
astVisitorClass
|
boolean |
bracesRequiredForElseIf
|
String |
name
|
int |
priority
|
Constructor Summary | |
ElseBlockBracesRule()
|
Method Summary |
---|
Methods inherited from class AbstractAstVisitorRule | |
---|---|
shouldApplyThisRuleTo |
Property Detail |
---|
Class astVisitorClass
boolean bracesRequiredForElseIf
String name
int priority
Constructor Detail |
---|
ElseBlockBracesRule()
Groovy Documentation