|
From: | Gopal.V <address@hidden> |
Subject: | [Jilc-patches] CVS: jilc/examples Test9.java,NONE,1.1 Test10.java,NONE,1.1 Test11.java,NONE,1.1 |
Date: | Tue, 26 Feb 2002 17:40:29 -0500 |
Update of /cvsroot/jilc/jilc/examples In directory subversions:/tmp/cvs-serv2300 Added Files: Test9.java Test10.java Test11.java Log Message: Tests for INTERFACE,ARRAYTYPE and Exception handling --- NEW FILE --- import java.lang.*; public class Test9 { public void testArray() { int a[]; a=new int[10]; int ma[][]; ma=new int[4][5]; for(int i=0;i<4;i++) for(int j=0;j<5;j++) { ma[i][j]=i+j; } } } --- NEW FILE --- import java.lang.*; import java.util.*; public class Test10 { public void testInterface() { Hashtable a=new Hashtable(); a.put("xyz","abc"); for (Enumeration e = a.elements() ; e.hasMoreElements() ;) { System.out.println(e.nextElement()); } } } --- NEW FILE --- import java.lang.*; public class Test11 { public void testThrows(String x) throws Exception,NumberFormatException { Integer.parseInt(x); throw new Exception("aaaah !"); } }
[Prev in Thread] | Current Thread | [Next in Thread] |