1 /*xml 2 <module name="Checker"> 3 <module name="TreeWalker"> 4 <module name="InterfaceIsType"> 5 <property name="allowMarkerInterfaces" value="false"/> 6 </module> 7 </module> 8 </module> 9 */ 10 11 package com.puppycrawl.tools.checkstyle.checks.design.interfaceistype; 12 13 // xdoc section -- start 14 class Example2 { 15 // violation below, 'interfaces should describe a type and hence have methods.' 16 interface Test1 { 17 int a = 3; 18 } 19 20 // violation below, 'interfaces should describe a type and hence have methods.' 21 interface Test2 { 22 23 } 24 25 interface Test3 { // ok, because it has a method. 26 int a = 3; 27 void test(); 28 } 29 } 30 // xdoc section -- end