diff --git a/pom.xml b/pom.xml index 3644d1015..f343fcb6f 100644 --- a/pom.xml +++ b/pom.xml @@ -191,7 +191,7 @@ UTF-8 ${project.version} 4.5.3 - 3.4 + 3.5.1 3.0.3 3.6 0.7.6.201602180812 @@ -607,12 +607,18 @@ true - + org.apache.maven.wagon wagon-ssh 2.10 + + + xerces + xercesImpl + 2.11.0 + diff --git a/src/xdocs/writingchecks.xml.vm b/src/xdocs/writingchecks.xml similarity index 97% rename from src/xdocs/writingchecks.xml.vm rename to src/xdocs/writingchecks.xml index a5e429ed9..c84ec2416 100644 --- a/src/xdocs/writingchecks.xml.vm +++ b/src/xdocs/writingchecks.xml @@ -196,7 +196,7 @@ java -cp checkstyle-${projectVersion}-all.jar com.puppycrawl.tools.checkstyle.gu but an abstract class to provide some helper methods. A Check provides methods that take an AST as an argument and perform the checking process for that AST, most prominently visitToken().

+ href="apidocs/com/puppycrawl/tools/checkstyle/api/AbstractCheck.html#visitToken-com.puppycrawl.tools.checkstyle.api.DetailAST-">visitToken().

It is important to understand that the individual Checks do no drive the AST traversal (it possible to traverse itself, but not recommended). @@ -208,16 +208,16 @@ java -cp checkstyle-${projectVersion}-all.jar com.puppycrawl.tools.checkstyle.gu

Before any visitor method is called, the TreeWalker will call beginTree() to give the Check a chance to do + href="apidocs/com/puppycrawl/tools/checkstyle/api/AbstractCheck.html#beginTree-com.puppycrawl.tools.checkstyle.api.DetailAST-">beginTree() to give the Check a chance to do some initialization. Then, when performing the recursive descend from the root to the leaf nodes, the visitToken() method is called. Unlike the basic examples in the pattern book, there is a visitToken() counterpart called leaveToken(). The TreeWalker will call that + href="apidocs/com/puppycrawl/tools/checkstyle/api/AbstractCheck.html#leaveToken-com.puppycrawl.tools.checkstyle.api.DetailAST-">leaveToken(). The TreeWalker will call that method to signal that the subtree below the node has been processed and the TreeWalker is backtracking from the node. After the root node has been left, the TreeWalker will call finishTree().

+ href="apidocs/com/puppycrawl/tools/checkstyle/api/AbstractCheck.html#finishTree-com.puppycrawl.tools.checkstyle.api.DetailAST-">finishTree().

@@ -550,7 +550,7 @@ java -classpath mycompanychecks.jar;checkstyle-${projectVersion}-all.jar \ inherit from AbstractFileSetCheck and override the abstract processFiltered(java.io.File, java.util.List) method and you're + href="apidocs/com/puppycrawl/tools/checkstyle/api/AbstractFileSetCheck.html#processFiltered-java.io.File-java.util.List-">processFiltered(java.io.File, java.util.List) method and you're done. A very simple example could fire an error if the number of files exceeds a certain limit. Here is a FileSetCheck that does just that: