01: package demo.ami;
02:
03: public class AsyncServerImpl extends AsyncServerPOA {
04: public int operation(int a, int b) {
05: try {
06: Thread.currentThread().sleep(2000);
07: } catch (InterruptedException e) {
08: }
09: return a + b;
10: }
11:
12: public int op2(int a) throws demo.ami.MyException {
13: try {
14: Thread.currentThread().sleep(2000);
15: } catch (InterruptedException e) {
16: }
17: throw new MyException("Hello exceptional world");
18: }
19: }
|