Created
March 1, 2015 20:40
-
-
Save KowalczykBartek/2ee7f8f6024d0e704e49 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public void rethrowException(String exceptionName) throws Exception { | |
try { | |
if (exceptionName.equals("First")) { | |
throw new FirstException(); | |
} else { | |
throw new SecondException(); | |
} | |
} catch (Exception e) { | |
throw e; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment