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    // violation below 'Parameterized constructors are not allowed'
20    public Example2(Object c) { }
21    // violation below 'Parameterized constructors are not allowed'
22    public Example2(int a, HashMap<String, Integer> b) { }
23    public Example2() { }
24  }
25  // xdoc section -- end