From c1863ec7e27f4e8ad2a0f83b9514a3cea35737c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lars=20K=C3=BChne?= Date: Sun, 18 May 2003 06:56:28 +0000 Subject: [PATCH] i18n of AvoidNestedBlocksCkeck --- .../tools/checkstyle/checks/AvoidNestedBlocksCheck.java | 3 +-- .../puppycrawl/tools/checkstyle/checks/messages.properties | 5 +++-- .../tools/checkstyle/checks/messages_de.properties | 1 + 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/checkstyle/com/puppycrawl/tools/checkstyle/checks/AvoidNestedBlocksCheck.java b/src/checkstyle/com/puppycrawl/tools/checkstyle/checks/AvoidNestedBlocksCheck.java index a05f2940c..7a71030be 100644 --- a/src/checkstyle/com/puppycrawl/tools/checkstyle/checks/AvoidNestedBlocksCheck.java +++ b/src/checkstyle/com/puppycrawl/tools/checkstyle/checks/AvoidNestedBlocksCheck.java @@ -63,8 +63,7 @@ public class AvoidNestedBlocksCheck extends Check public void visitToken(DetailAST aAST) { if (aAST.getParent().getType() == TokenTypes.SLIST) { - // TODO: i18n - log(aAST.getLineNo(), aAST.getColumnNo(), "Avoid nested blocks"); + log(aAST.getLineNo(), aAST.getColumnNo(), "block.nested"); } } diff --git a/src/checkstyle/com/puppycrawl/tools/checkstyle/checks/messages.properties b/src/checkstyle/com/puppycrawl/tools/checkstyle/checks/messages.properties index c1b629339..2efc517e9 100644 --- a/src/checkstyle/com/puppycrawl/tools/checkstyle/checks/messages.properties +++ b/src/checkstyle/com/puppycrawl/tools/checkstyle/checks/messages.properties @@ -58,6 +58,7 @@ mod.order=''{0}'' modifier out of order with the JLS suggestions. block.noStmt=Must have at least one statement. block.empty=Empty {0} block. +block.nested=Avoid nested blocks. maxParam=More than {0,number,integer} parameters. @@ -78,8 +79,8 @@ doublechecked.locking.avoid=The double-checked locking idiom is broken and shoul design.forInheritance=Method ''{0}'' is not designed for inheritance - needs to be abstract, final or empty. -final.class=Class {0} should be declared as final -missing.switch.default=switch without \"default\" clause +final.class=Class {0} should be declared as final. +missing.switch.default=switch without \"default\" clause. empty.statement=Empty statement. diff --git a/src/checkstyle/com/puppycrawl/tools/checkstyle/checks/messages_de.properties b/src/checkstyle/com/puppycrawl/tools/checkstyle/checks/messages_de.properties index 16e6d5b00..354bb0b05 100644 --- a/src/checkstyle/com/puppycrawl/tools/checkstyle/checks/messages_de.properties +++ b/src/checkstyle/com/puppycrawl/tools/checkstyle/checks/messages_de.properties @@ -59,6 +59,7 @@ mod.order=''{0}'' Modifier weicht von der empfohlenen Modifier-Reihenfolge aus d block.noStmt=Muss mindestens ein Statement beinhalten. block.empty=Leerer {0} Block. +block.nested=Verschachtelte Blöcke sollten vermieden werden. maxParam=Mehr als {0,number,integer} Parameter.