2nd try. not sure why the whole file shown in diff before

pull/347/head
Nitin 10 years ago
parent acb7d41961
commit f6e9793034

@ -113,9 +113,10 @@ public final class PoolElf
if (upperName.startsWith("TRANSACTION_")) { if (upperName.startsWith("TRANSACTION_")) {
Field field = Connection.class.getField(upperName); Field field = Connection.class.getField(upperName);
return field.getInt(null); return field.getInt(null);
} else { }
else {
final int level = Integer.parseInt(transactionIsolationName); final int level = Integer.parseInt(transactionIsolationName);
// its number //its number
switch (level) { switch (level) {
case Connection.TRANSACTION_READ_UNCOMMITTED: case Connection.TRANSACTION_READ_UNCOMMITTED:
case Connection.TRANSACTION_READ_COMMITTED: case Connection.TRANSACTION_READ_COMMITTED:
@ -127,7 +128,8 @@ public final class PoolElf
throw new IllegalArgumentException(); throw new IllegalArgumentException();
} }
} }
} catch (Exception e) { }
catch (Exception e) {
throw new IllegalArgumentException("Invalid transaction isolation value: " + transactionIsolationName); throw new IllegalArgumentException("Invalid transaction isolation value: " + transactionIsolationName);
} }
} }

Loading…
Cancel
Save