If you're going to have your exception handling for Exception inline, and don't want to repeat it, then the only solution is the OP solution.
However, if you can put the common exception handling into a function, then this would be neat:
try {
//Exceptions may happen
} catch (Exception1 exception1) {
//do stuff only in case of Exception1
} catch(Exception2 e) {
doCommonStuff();
doException2Stuff();
} catch(Exception e) {
doCommonStuff();
}
However, the above may lead to a small problem in terms of whether you want to pass control to outside of the try/catch block, or whether you're hoping to return a value, or even throw another exception.
You may find that although all paths of your code DO throw an exception, that the above construct, of using common exception handler methods, may look to the compiler like some control paths don't.
You can, therefore, express a common exception handler, that always throws an exception like this:
private <T> T throwLastException(Exception2 input) {
// blah blah blah
throw new SomeException();
}
and this can be called as part of a return statement that appears to guarantee the calling function returns a value, when in fact it's just telling the compiler not to worry :)