1 23 package org.hammurapi.inspectors.testcases.fixes; 24 25 import org.hammurapi.inspectors.testcases.HammurapiTestCasesException; 26 27 32 public class ForLoopControlVariablesRuleFixTestCase { 33 34 private static org.apache.log4j.Logger logger = 35 org.apache.log4j.Logger.getRootLogger(); 36 37 38 public void searchObj(final java.util.Iterator iter, final Object anObj) 39 throws HammurapiTestCasesException { 40 if (iter.hasNext()) { 41 42 for (Object obj = iter.next(); iter.hasNext(); obj = iter.next()) { 44 if (obj.equals(anObj)) { 45 throw new HammurapiTestCasesException(obj.toString()); 46 } 47 } 48 50 for (int i=9, j=100; i<j; i++, j-=i) { 51 int z=j*i; 52 } 53 54 int i=300; 55 String gga; 56 for (i=28, gga="Internationalization"; i>gga.length(); i--, gga+="X") { 57 String gogo=gga.substring(gga.length()-5); 58 } 59 60 } 61 } 62 } 63 64 | Popular Tags |