
org.sonar.l10n.squidjava.rules.squid.RightCurlyBraceStartLineCheck.html Maven / Gradle / Ivy
Sharing some coding conventions is a key point to make it possible for a team to efficiently collaborate.
This rule make it mandatory to place right curly braces at the beginning of lines of code.
The following code snippet illustrates this rule:
public void myMethod() {
if(something) {
executeTask();} // Non-Compliant
else if (somethingElse) {
doSomethingElse();
} // Compliant
try {
generateOrder();
} finally { // Compliant
closeConnection();
} // Compliant
try {
generateOrder();
} finally { // Compliant
closeConnection(); } // Non-Compliant
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy