1 /*xml 2 <module name="Checker"> 3 <module name="TreeWalker"> 4 <module name="MethodName"/> 5 <module name="SuppressionXpathSingleFilter"> 6 <property name="checks" value="MethodName"/> 7 <property name="message" value="MyMethod[0-9]"/> 8 </module> 9 </module> 10 </module> 11 */ 12 13 package com.puppycrawl.tools.checkstyle.filters.suppressionxpathsinglefilter; 14 15 // xdoc section -- start 16 public class Example2 { 17 // filtered violation below 'Name 'MyMethod1' must match pattern' 18 public void MyMethod1() {} 19 // filtered violation below 'Name 'MyMethod2' must match pattern' 20 public void MyMethod2() {} 21 // violation below 'Name 'MyMethodA' must match pattern' 22 public void MyMethodA() {} 23 } 24 // xdoc section -- end