View Javadoc
1   /*xml
2   <module name="Checker">
3     <module name="TreeWalker">
4       <module name="MatchXpath">
5         <property name="query"
6              value="//CTOR_DEF[count(./PARAMETERS/*) > 0]"/>
7         <message key="matchxpath.match"
8              value="Parameterized constructors are not allowed"/>
9       </module>
10    </module>
11  </module>
12  */
13  package com.puppycrawl.tools.checkstyle.checks.coding.matchxpath;
14  
15  import java.util.HashMap;
16  
17  // xdoc section -- start
18  public class Example2 {
19    public Example2(Object c) { } // violation
20    public Example2(int a, HashMap<String, Integer> b) { } // violation
21    public Example2() { }
22  }
23  // xdoc section -- end