source: trunk/src/test/java/omq/test/multiProcess/NumberImpl.java @ 54

Last change on this file since 54 was 54, checked in by stoda, 11 years ago

Adding @MultiMethod?
Broker is not a singleton.

File size: 665 bytes
Line 
1package omq.test.multiProcess;
2
3import omq.client.annotation.AsyncMethod;
4import omq.client.annotation.MultiMethod;
5import omq.client.annotation.SyncMethod;
6import omq.server.RemoteObject;
7
8public class NumberImpl extends RemoteObject implements Number {
9        /**
10         *
11         */
12        private static final long serialVersionUID = 1L;
13        private int x = 0;
14
15        public NumberImpl() {
16        }
17
18        public NumberImpl(int x) {
19                this.x = x;
20        }
21
22        @Override
23        @SyncMethod
24        public void setNumber(int x) {
25                this.x = x;
26        }
27
28        @Override
29        @SyncMethod(timeout = 1000)
30        public int getNumer() {
31                return x;
32        }
33
34        @Override
35        @MultiMethod
36        @AsyncMethod
37        public void setMultiNumber(int x) {
38                this.x = x;
39        }
40
41}
Note: See TracBrowser for help on using the repository browser.