Created
May 16, 2020 17:03
-
-
Save benweidig/f3499514552e3047c5feaaf59536eb45 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
try { | |
// might throw IOException | |
doWork(); | |
doMoreWorkRequireingCleanup(); | |
} | |
catch (IOException e) { | |
throw new RuntimeExcetpion(e) | |
} | |
finally { | |
// Will be called regardless of IOException | |
cleanup(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment