Advertisement
Guest User

Untitled

a guest
Oct 4th, 2020
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.77 KB | None | 0 0
  1. try{
  2.        load0(res0);
  3.        someCodeHere();
  4.        load1(res1);
  5.        someOtherCodeHere();
  6.        load2(res2);
  7.        yetAnotherCodeHere();
  8.        load3(res3);
  9.        andYetAnotherCodeHere();
  10.     }
  11.     catch(EType0 e0){
  12.         throw new Exception("whatever happens lol", e0);
  13.     }
  14.     catch(EType1 e1){
  15.         unload0(res0);
  16.         throw new Exception("whatever happens lol", e1);
  17.     }
  18.     catch(EType2 e2){
  19.         unload1(res1);
  20.         unload0(res0);
  21.         throw new Exception("whatever happens lol", e2);
  22.     }
  23.     catch(EType3 e3){
  24.         unload2(res2);
  25.         unload1(res1);
  26.         unload0(res0);
  27.         throw new Exception("whatever happens lol", e3);
  28.     }
  29.     unload3(res3);
  30.     unload2(res2);
  31.     unload1(res1);
  32.     unload0(res0);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement