# HG changeset patch # User Martin van Dinther <martin.van.dinther@monetdbsolutions.com> # Date 1507825589 -7200 # Node ID 91f2bab75b9b091b8c6ded5e6ba73a480c0d823e # Parent e0f76fedafc85d25468c6abd09cc21967370b301 Resolving javac warnings: Test_Cmanycon.java:34: warning: [rawtypes] found raw type: Iterator for (Iterator it = cons.iterator(); it.hasNext(); i++) { ^ missing type arguments for generic class Iterator<E> where E is a type-variable: E extends Object declared in interface Iterator Test_PSmanycon.java:34: warning: [rawtypes] found raw type: Iterator for (Iterator it = pss.iterator(); it.hasNext(); i++) { ^ missing type arguments for generic class Iterator<E> where E is a type-variable: E extends Object declared in interface Iterator diff --git a/tests/Test_Cmanycon.java b/tests/Test_Cmanycon.java --- a/tests/Test_Cmanycon.java +++ b/tests/Test_Cmanycon.java @@ -31,8 +31,8 @@ public class Test_Cmanycon { // now try to nicely close them i = 0; - for (Iterator it = cons.iterator(); it.hasNext(); i++) { - Connection con = (Connection)(it.next()); + for (Iterator<Connection> it = cons.iterator(); it.hasNext(); i++) { + Connection con = it.next(); // see if the connection still works System.out.print("Closing Connection " + i + "..."); diff --git a/tests/Test_PSmanycon.java b/tests/Test_PSmanycon.java --- a/tests/Test_PSmanycon.java +++ b/tests/Test_PSmanycon.java @@ -31,8 +31,8 @@ public class Test_PSmanycon { // now try to nicely execute them i = 0; - for (Iterator it = pss.iterator(); it.hasNext(); i++) { - PreparedStatement pstmt = (PreparedStatement)(it.next()); + for (Iterator<PreparedStatement> it = pss.iterator(); it.hasNext(); i++) { + PreparedStatement pstmt = it.next(); // see if the connection still works System.out.print("Executing PreparedStatement " + i + "...");