views:

105

answers:

1
  try {
      ...
  }  catch (SQLException sqle) {
      String theError = (sqle).getSQLState();
      ...
  }

What does surrounding sqle with parenthesis do? Anything?

Just curious.

+5  A: 

Quick reply - Nothing.

Longer reply - It might be a vestigial remnant of an inline cast:

((SomeMoreSpecificException)sqle).get...
Software Monkey