1
2
3
4
5
6
7
8
9
10 package
11 cz.cuni.amis.pogamut.udk.communication.messages.gbcommands;
12 import java.util.*;
13 import javax.vecmath.*;
14 import cz.cuni.amis.pogamut.base.communication.messages.*;
15 import cz.cuni.amis.pogamut.base.communication.worldview.*;
16 import cz.cuni.amis.pogamut.base.communication.worldview.event.*;
17 import cz.cuni.amis.pogamut.base.communication.worldview.object.*;
18 import cz.cuni.amis.pogamut.base.communication.translator.event.*;
19 import cz.cuni.amis.pogamut.base3d.worldview.object.*;
20 import cz.cuni.amis.pogamut.base3d.worldview.object.event.*;
21 import cz.cuni.amis.pogamut.unreal.communication.messages.UnrealId;
22 import cz.cuni.amis.pogamut.udk.communication.messages.*;
23 import cz.cuni.amis.pogamut.udk.communication.worldview.objects.*;
24 import cz.cuni.amis.pogamut.udk.communication.translator.itemdescriptor.*;
25 import cz.cuni.amis.pogamut.udk.communication.messages.ItemType.Category;
26 import cz.cuni.amis.utils.exception.*;
27 import cz.cuni.amis.pogamut.base.communication.translator.event.IWorldObjectUpdateResult.Result;
28 import cz.cuni.amis.utils.SafeEquals;
29 import cz.cuni.amis.pogamut.multi.communication.worldview.object.*;
30
31
32
33
34
35
36
37
38
39
40
41
42
43 public class
44 SetLock extends
45 CommandMessage
46
47 {
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64 public SetLock(
65 boolean BotServer, boolean ControlServer) {
66
67 this.BotServer = BotServer;
68
69 this.ControlServer = ControlServer;
70
71 }
72
73
74
75
76
77
78
79
80
81
82
83
84 public SetLock() {
85 }
86
87
88
89
90
91
92
93
94 protected
95 boolean BotServer =
96 false;
97
98
99
100
101
102
103 public
104 boolean isBotServer() {
105 return
106 BotServer;
107 }
108
109
110
111
112
113
114
115 public SetLock setBotServer(boolean BotServer) {
116 this.BotServer = BotServer;
117 return this;
118 }
119
120
121
122
123
124 protected
125 boolean ControlServer =
126 false;
127
128
129
130
131
132
133 public
134 boolean isControlServer() {
135 return
136 ControlServer;
137 }
138
139
140
141
142
143
144
145 public SetLock setControlServer(boolean ControlServer) {
146 this.ControlServer = ControlServer;
147 return this;
148 }
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171 public SetLock(SetLock original) {
172
173 this.BotServer=original.BotServer;
174
175 this.ControlServer=original.ControlServer;
176
177 }
178
179
180
181
182 public String toString() {
183 return
184
185 toMessage();
186
187 }
188
189 public String toHtmlString() {
190 return super.toString() +
191
192 "<b>BotServer</b> : " +
193 String.valueOf(BotServer) +
194 " <br/> " +
195
196 "<b>ControlServer</b> : " +
197 String.valueOf(ControlServer) +
198 " <br/> " +
199 "";
200 }
201
202
203
204 public String toMessage() {
205 StringBuffer buf = new StringBuffer();
206 buf.append("SETLOCK");
207
208 buf.append(" {BotServer " + BotServer + "}");
209
210 buf.append(" {ControlServer " + ControlServer + "}");
211
212 return buf.toString();
213 }
214
215 }
216
217