1 | package Counter; |
2 | public class CountImpl extends _sk_Count implements Count { |
3 | private int sum; |
4 | CountImpl(String name) { // Count object constructor |
5 | super(name); sum = 0; |
6 | System.out.println("Count Object Created!"); |
7 | } |
8 | public int sum() throws CORBA.Exception { // accessor method: getSum |
9 | return sum; |
10 | } |
11 | public void sum(int val) throws CORBA.Exception { // accessor method: setSum |
12 | sum = val; |
13 | } |
14 | public int increment() throws CORBA.Exception { // increment method |
15 | sum++; return sum: |
16 | } |
17 | } |
18 | |
19 | |
20 | |
21 | Note: This code is created automatically by |
22 | IDL->Java pre-compiler from the IDL spec |