2 * Copyright (c) 2010-2020 Contributors to the openHAB project
4 * See the NOTICE file(s) distributed with this work for additional
7 * This program and the accompanying materials are made available under the
8 * terms of the Eclipse Public License 2.0 which is available at
9 * http://www.eclipse.org/legal/epl-2.0
11 * SPDX-License-Identifier: EPL-2.0
13 package org.openhab.binding.velux.internal.things;
16 import java.util.function.Function;
17 import java.util.stream.Collectors;
18 import java.util.stream.Stream;
20 import org.eclipse.jdt.annotation.NonNullByDefault;
24 * The {@link VeluxKLFAPI} class defines common KLF200 API constants, which are
25 * used across the whole binding.
27 * It provides the Enumeration of available API message identifiers as well as
28 * constants which describe the KLF200 API restrictions.
30 * Classes/Enumeration available:
32 * <LI>Enumeration {@link Command} provides command name, coding and description.</LI>
33 * <LI>Class {@link CommandName} to handle symbolic API names.</LI>
34 * <LI>Class {@link CommandNumber} to handle API code.</LI>
36 * Constants available:
38 * <LI>{@link #KLF_SYSTEMTABLE_MAX} provides limits of the System table.</LI>
42 * @author Guenther Schreiner - Initial contribution.
45 public class VeluxKLFAPI {
50 * System table index parameter - an be a number from 0 to 203.
53 * "https://velcdn.azureedge.net/~/media/com/api/klf200/technical%20specification%20for%20klf%20200%20api.pdf#page=25">KLF200
56 public static final int KLF_SYSTEMTABLE_MAX = 203;
61 * Handle symbolic names of the {@link VeluxKLFAPI}.
65 * <LI>Constructor {@link CommandName} by String.</LI>
66 * <LI>Method {@link toString} to return a String.</LI>
70 public static class CommandName {
73 CommandName(String name) {
78 public String toString() {
84 * Handle API codings of the {@link VeluxKLFAPI}.
88 * <LI>CommandNumber {@link CommandName} by short.</LI>
89 * <LI>Method {@link toShort} to return a short.</LI>
90 * <LI>Method {@link toString} to return a well-formatted String.</LI>
94 public static class CommandNumber {
95 private short commandNumber;
97 public CommandNumber(short commandNumber) {
98 this.commandNumber = commandNumber;
101 public short toShort() {
102 return commandNumber;
106 public String toString() {
107 return "0x" + Integer.toHexString(new Short(commandNumber).intValue());
112 * Enumeration of complete API as definition of a
113 * List of Gateway commands.
116 * "https://velcdn.azureedge.net/~/media/com/api/klf200/technical%20specification%20for%20klf%20200%20api.pdf#page=115">Appendix
117 * 3: List of Gateway commands</a>
121 * <LI>Constructor {@link Command} by String.</LI>
122 * <LI>Method {@link getCommand} to return a {@link CommandNumber}.</LI>
123 * <LI>Method {@link getDescription} to return a description as String.</LI>
124 * <LI>Method {@link get} to return a {@link Command} based on the given <B>int</B>.</LI>
127 public enum Command {
128 // Special item: unrecognized command
129 UNDEFTYPE((short) -1, "Unknown command."),
130 // Special item: Shutdown of the connection
131 GW_OPENHAB_CLOSE((short) -2, "openHAB connection shutdown command."),
132 // Special item: Shutdown of the connection
133 GW_OPENHAB_RECEIVEONLY((short) -3, "openHAB receive command."),
134 // Velux specific commands
135 GW_ERROR_NTF((short) 0x0000, "Provides information on what triggered the error."),
136 GW_REBOOT_REQ((short) 0x0001, "Request gateway to reboot."),
137 GW_REBOOT_CFM((short) 0x0002, "Acknowledge to GW_REBOOT_REQ command."),
138 GW_SET_FACTORY_DEFAULT_REQ((short) 0x0003,
139 "Request gateway to clear system table, scene table and set Ethernet settings to factory default. Gateway will reboot."),
140 GW_SET_FACTORY_DEFAULT_CFM((short) 0x0004, "Acknowledge to GW_SET_FACTORY_DEFAULT_REQ command."),
141 GW_GET_VERSION_REQ((short) 0x0008, "Request version information."),
142 GW_GET_VERSION_CFM((short) 0x0009, "Acknowledge to GW_GET_VERSION_REQ command."),
143 GW_GET_PROTOCOL_VERSION_REQ((short) 0x000A, "Request KLF 200 API protocol version."),
144 GW_GET_PROTOCOL_VERSION_CFM((short) 0x000B, "Acknowledge to GW_GET_PROTOCOL_VERSION_REQ command."),
145 GW_GET_STATE_REQ((short) 0x000C, "Request the state of the gateway"),
146 GW_GET_STATE_CFM((short) 0x000D, "Acknowledge to GW_GET_STATE_REQ command."),
148 GW_LEAVE_LEARN_STATE_REQ((short) 0x000E, "Request gateway to leave learn state."),
149 GW_LEAVE_LEARN_STATE_CFM((short) 0x000F, "Acknowledge to GW_LEAVE_LEARN_STATE_REQ command."),
150 GW_GET_NETWORK_SETUP_REQ((short) 0x00E0, "Request network parameters."),
151 GW_GET_NETWORK_SETUP_CFM((short) 0x00E1, "Acknowledge to GW_GET_NETWORK_SETUP_REQ."),
152 GW_SET_NETWORK_SETUP_REQ((short) 0x00E2, "Set network parameters."),
153 GW_SET_NETWORK_SETUP_CFM((short) 0x00E3, "Acknowledge to GW_SET_NETWORK_SETUP_REQ."),
155 GW_CS_GET_SYSTEMTABLE_DATA_REQ((short) 0x0100, "Request a list of nodes in the gateways system table."),
156 GW_CS_GET_SYSTEMTABLE_DATA_CFM((short) 0x0101, "Acknowledge to GW_CS_GET_SYSTEMTABLE_DATA_REQ"),
157 GW_CS_GET_SYSTEMTABLE_DATA_NTF((short) 0x0102,
158 "Acknowledge to GW_CS_GET_SYSTEM_TABLE_DATA_REQList of nodes in the gateways systemtable."),
159 GW_CS_DISCOVER_NODES_REQ((short) 0x0103, "Start CS DiscoverNodes macro in KLF200."),
160 GW_CS_DISCOVER_NODES_CFM((short) 0x0104, "Acknowledge to GW_CS_DISCOVER_NODES_REQ command."),
161 GW_CS_DISCOVER_NODES_NTF((short) 0x0105, "Acknowledge to GW_CS_DISCOVER_NODES_REQ command."),
162 GW_CS_REMOVE_NODES_REQ((short) 0x0106, "Remove one or more nodes in the systemtable."),
163 GW_CS_REMOVE_NODES_CFM((short) 0x0107, "Acknowledge to GW_CS_REMOVE_NODES_REQ."),
164 GW_CS_VIRGIN_STATE_REQ((short) 0x0108, "Clear systemtable and delete system key."),
165 GW_CS_VIRGIN_STATE_CFM((short) 0x0109, "Acknowledge to GW_CS_VIRGIN_STATE_REQ."),
166 GW_CS_CONTROLLER_COPY_REQ((short) 0x010A,
167 "Setup KLF200 to get or give a system to or from another io-homecontrol® remote control. By a system means all nodes in the systemtable and the system key."),
168 GW_CS_CONTROLLER_COPY_CFM((short) 0x010B, "Acknowledge to GW_CS_CONTROLLER_COPY_REQ."),
169 GW_CS_CONTROLLER_COPY_NTF((short) 0x010C, "Acknowledge to GW_CS_CONTROLLER_COPY_REQ."),
170 GW_CS_CONTROLLER_COPY_CANCEL_NTF((short) 0x010D, "Cancellation of system copy to other controllers."),
171 GW_CS_RECEIVE_KEY_REQ((short) 0x010E, "Receive system key from another controller."),
172 GW_CS_RECEIVE_KEY_CFM((short) 0x010F, "Acknowledge to GW_CS_RECEIVE_KEY_REQ."),
173 GW_CS_RECEIVE_KEY_NTF((short) 0x0110, "Acknowledge to GW_CS_RECEIVE_KEY_REQ with status."),
174 GW_CS_PGC_JOB_NTF((short) 0x0111,
175 "Information on Product Generic Configuration job initiated by press on PGC button."),
176 GW_CS_SYSTEM_TABLE_UPDATE_NTF((short) 0x0112,
177 "Broadcasted to all clients and gives information about added and removed actuator nodes in system table."),
178 GW_CS_GENERATE_NEW_KEY_REQ((short) 0x0113, "Generate new system key and update actuators in systemtable."),
179 GW_CS_GENERATE_NEW_KEY_CFM((short) 0x0114, "Acknowledge to GW_CS_GENERATE_NEW_KEY_REQ."),
180 GW_CS_GENERATE_NEW_KEY_NTF((short) 0x0115, "Acknowledge to GW_CS_GENERATE_NEW_KEY_REQ with status."),
181 GW_CS_REPAIR_KEY_REQ((short) 0x0116, "Update key in actuators holding an old key."),
182 GW_CS_REPAIR_KEY_CFM((short) 0x0117, "Acknowledge to GW_CS_REPAIR_KEY_REQ."),
183 GW_CS_REPAIR_KEY_NTF((short) 0x0118, "Acknowledge to GW_CS_REPAIR_KEY_REQ with status."),
184 GW_CS_ACTIVATE_CONFIGURATION_MODE_REQ((short) 0x0119,
185 "Request one or more actuator to open for configuration."),
186 GW_CS_ACTIVATE_CONFIGURATION_MODE_CFM((short) 0x011A, "Acknowledge to GW_CS_ACTIVATE_CONFIGURATION_MODE_REQ."),
188 GW_GET_NODE_INFORMATION_REQ((short) 0x0200, "Request extended information of one specific actuator node."),
189 GW_GET_NODE_INFORMATION_CFM((short) 0x0201, "Acknowledge to GW_GET_NODE_INFORMATION_REQ."),
190 GW_GET_NODE_INFORMATION_NTF((short) 0x0210, "Acknowledge to GW_GET_NODE_INFORMATION_REQ."),
191 GW_GET_ALL_NODES_INFORMATION_REQ((short) 0x0202, "Request extended information of all nodes."),
192 GW_GET_ALL_NODES_INFORMATION_CFM((short) 0x0203, "Acknowledge to GW_GET_ALL_NODES_INFORMATION_REQ"),
193 GW_GET_ALL_NODES_INFORMATION_NTF((short) 0x0204,
194 "Acknowledge to GW_GET_ALL_NODES_INFORMATION_REQ. Holds node information"),
195 GW_GET_ALL_NODES_INFORMATION_FINISHED_NTF((short) 0x0205,
196 "Acknowledge to GW_GET_ALL_NODES_INFORMATION_REQ. No more nodes."),
197 GW_SET_NODE_VARIATION_REQ((short) 0x0206, "Set node variation."),
198 GW_SET_NODE_VARIATION_CFM((short) 0x0207, "Acknowledge to GW_SET_NODE_VARIATION_REQ."),
199 GW_SET_NODE_NAME_REQ((short) 0x0208, "Set node name."),
200 GW_SET_NODE_NAME_CFM((short) 0x0209, "Acknowledge to GW_SET_NODE_NAME_REQ."),
201 GW_SET_NODE_VELOCITY_REQ((short) 0x020A, "Set node velocity."),
202 GW_SET_NODE_VELOCITY_CFM((short) 0x020B, "Acknowledge to GW_SET_NODE_VELOCITY_REQ."),
203 GW_NODE_INFORMATION_CHANGED_NTF((short) 0x020C, "Information has been updated."),
204 GW_NODE_STATE_POSITION_CHANGED_NTF((short) 0x0211, "Information has been updated."),
205 GW_SET_NODE_ORDER_AND_PLACEMENT_REQ((short) 0x020D, "Set search order and room placement."),
206 GW_SET_NODE_ORDER_AND_PLACEMENT_CFM((short) 0x020E, "Acknowledge to GW_SET_NODE_ORDER_AND_PLACEMENT_REQ."),
208 GW_GET_GROUP_INFORMATION_REQ((short) 0x0220, "Request information about all defined groups."),
209 GW_GET_GROUP_INFORMATION_CFM((short) 0x0221, "Acknowledge to GW_GET_GROUP_INFORMATION_REQ."),
210 GW_GET_GROUP_INFORMATION_NTF((short) 0x0230, "Acknowledge to GW_GET_NODE_INFORMATION_REQ."),
211 GW_SET_GROUP_INFORMATION_REQ((short) 0x0222, "Change an existing group."),
212 GW_SET_GROUP_INFORMATION_CFM((short) 0x0223, "Acknowledge to GW_SET_GROUP_INFORMATION_REQ."),
213 GW_GROUP_INFORMATION_CHANGED_NTF((short) 0x0224,
214 "Broadcast to all, about group information of a group has been changed."),
215 GW_DELETE_GROUP_REQ((short) 0x0225, "Delete a group."),
216 GW_DELETE_GROUP_CFM((short) 0x0226, "Acknowledge to GW_DELETE_GROUP_INFORMATION_REQ."),
217 GW_NEW_GROUP_REQ((short) 0x0227, "Request new group to be created."),
218 GW_NEW_GROUP_CFM((short) 0x0228, ""),
219 GW_GET_ALL_GROUPS_INFORMATION_REQ((short) 0x0229, "Request information about all defined groups."),
220 GW_GET_ALL_GROUPS_INFORMATION_CFM((short) 0x022A, "Acknowledge to GW_GET_ALL_GROUPS_INFORMATION_REQ."),
221 GW_GET_ALL_GROUPS_INFORMATION_NTF((short) 0x022B, "Acknowledge to GW_GET_ALL_GROUPS_INFORMATION_REQ."),
222 GW_GET_ALL_GROUPS_INFORMATION_FINISHED_NTF((short) 0x022C, "Acknowledge to GW_GET_ALL_GROUPS_INFORMATION_REQ."),
223 GW_GROUP_DELETED_NTF((short) 0x022D,
224 "GW_GROUP_DELETED_NTF is broadcasted to all, when a group has been removed."),
225 GW_HOUSE_STATUS_MONITOR_ENABLE_REQ((short) 0x0240, "Enable house status monitor."),
226 GW_HOUSE_STATUS_MONITOR_ENABLE_CFM((short) 0x0241, "Acknowledge to GW_HOUSE_STATUS_MONITOR_ENABLE_REQ."),
227 GW_HOUSE_STATUS_MONITOR_DISABLE_REQ((short) 0x0242, "Disable house status monitor."),
228 GW_HOUSE_STATUS_MONITOR_DISABLE_CFM((short) 0x0243, "Acknowledge to GW_HOUSE_STATUS_MONITOR_DISABLE_REQ."),
230 GW_COMMAND_SEND_REQ((short) 0x0300, "Send activating command direct to one or more io-homecontrol® nodes."),
231 GW_COMMAND_SEND_CFM((short) 0x0301, "Acknowledge to GW_COMMAND_SEND_REQ."),
232 GW_COMMAND_RUN_STATUS_NTF((short) 0x0302, "Gives run status for io-homecontrol® node."),
233 GW_COMMAND_REMAINING_TIME_NTF((short) 0x0303,
234 "Gives remaining time before io-homecontrol® node enter target position."),
235 GW_SESSION_FINISHED_NTF((short) 0x0304,
236 "Command send, Status request, Wink, Mode or Stop session is finished."),
237 GW_STATUS_REQUEST_REQ((short) 0x0305, "Get status request from one or more io-homecontrol® nodes."),
238 GW_STATUS_REQUEST_CFM((short) 0x0306, "Acknowledge to GW_STATUS_REQUEST_REQ."),
239 GW_STATUS_REQUEST_NTF((short) 0x0307,
240 "Acknowledge to GW_STATUS_REQUEST_REQ. Status request from one or more io-homecontrol® nodes."),
241 GW_WINK_SEND_REQ((short) 0x0308, "Request from one or more io-homecontrol® nodes to Wink."),
242 GW_WINK_SEND_CFM((short) 0x0309, "Acknowledge to GW_WINK_SEND_REQ"),
243 GW_WINK_SEND_NTF((short) 0x030A, "Status info for performed wink request."),
245 GW_SET_LIMITATION_REQ((short) 0x0310, "Set a parameter limitation in an actuator."),
246 GW_SET_LIMITATION_CFM((short) 0x0311, "Acknowledge to GW_SET_LIMITATION_REQ."),
247 GW_GET_LIMITATION_STATUS_REQ((short) 0x0312, "Get parameter limitation in an actuator."),
248 GW_GET_LIMITATION_STATUS_CFM((short) 0x0313, "Acknowledge to GW_GET_LIMITATION_STATUS_REQ."),
249 GW_LIMITATION_STATUS_NTF((short) 0x0314, "Hold information about limitation."),
250 GW_MODE_SEND_REQ((short) 0x0320, "Send Activate Mode to one or more io-homecontrol® nodes."),
251 GW_MODE_SEND_CFM((short) 0x0321, "Acknowledge to GW_MODE_SEND_REQ"),
252 GW_MODE_SEND_NTF((short) 0x0322, "Notify with Mode activation info."),
254 GW_INITIALIZE_SCENE_REQ((short) 0x0400, "Prepare gateway to record a scene."),
255 GW_INITIALIZE_SCENE_CFM((short) 0x0401, "Acknowledge to GW_INITIALIZE_SCENE_REQ."),
256 GW_INITIALIZE_SCENE_NTF((short) 0x0402, "Acknowledge to GW_INITIALIZE_SCENE_REQ."),
257 GW_INITIALIZE_SCENE_CANCEL_REQ((short) 0x0403, "Cancel record scene process."),
258 GW_INITIALIZE_SCENE_CANCEL_CFM((short) 0x0404, "Acknowledge to GW_INITIALIZE_SCENE_CANCEL_REQ command."),
259 GW_RECORD_SCENE_REQ((short) 0x0405, "Store actuator positions changes since GW_INITIALIZE_SCENE, as a scene."),
260 GW_RECORD_SCENE_CFM((short) 0x0406, "Acknowledge to GW_RECORD_SCENE_REQ."),
261 GW_RECORD_SCENE_NTF((short) 0x0407, "Acknowledge to GW_RECORD_SCENE_REQ."),
262 GW_DELETE_SCENE_REQ((short) 0x0408, "Delete a recorded scene."),
263 GW_DELETE_SCENE_CFM((short) 0x0409, "Acknowledge to GW_DELETE_SCENE_REQ."),
264 GW_RENAME_SCENE_REQ((short) 0x040A, "Request a scene to be renamed."),
265 GW_RENAME_SCENE_CFM((short) 0x040B, "Acknowledge to GW_RENAME_SCENE_REQ."),
266 GW_GET_SCENE_LIST_REQ((short) 0x040C, "Request a list of scenes."),
267 GW_GET_SCENE_LIST_CFM((short) 0x040D, "Acknowledge to GW_GET_SCENE_LIST."),
268 GW_GET_SCENE_LIST_NTF((short) 0x040E, "Acknowledge to GW_GET_SCENE_LIST."),
269 GW_GET_SCENE_INFOAMATION_REQ((short) 0x040F, "Request extended information for one given scene."),
270 GW_GET_SCENE_INFOAMATION_CFM((short) 0x0410, "Acknowledge to GW_GET_SCENE_INFOAMATION_REQ."),
271 GW_GET_SCENE_INFOAMATION_NTF((short) 0x0411, "Acknowledge to GW_GET_SCENE_INFOAMATION_REQ."),
272 GW_ACTIVATE_SCENE_REQ((short) 0x0412, "Request gateway to enter a scene."),
273 GW_ACTIVATE_SCENE_CFM((short) 0x0413, "Acknowledge to GW_ACTIVATE_SCENE_REQ."),
274 GW_STOP_SCENE_REQ((short) 0x0415, "Request all nodes in a given scene to stop at their current position."),
275 GW_STOP_SCENE_CFM((short) 0x0416, "Acknowledge to GW_STOP_SCENE_REQ."),
276 GW_SCENE_INFORMATION_CHANGED_NTF((short) 0x0419, "A scene has either been changed or removed."),
278 GW_ACTIVATE_PRODUCTGROUP_REQ((short) 0x0447, "Activate a product group in a given direction."),
279 GW_ACTIVATE_PRODUCTGROUP_CFM((short) 0x0448, "Acknowledge to GW_ACTIVATE_PRODUCTGROUP_REQ."),
280 GW_ACTIVATE_PRODUCTGROUP_NTF((short) 0x0449, "Acknowledge to GW_ACTIVATE_PRODUCTGROUP_REQ."),
282 GW_GET_CONTACT_INPUT_LINK_LIST_REQ((short) 0x0460,
283 "Get list of assignments to all Contact Input to scene or product group."),
284 GW_GET_CONTACT_INPUT_LINK_LIST_CFM((short) 0x0461, "Acknowledge to GW_GET_CONTACT_INPUT_LINK_LIST_REQ."),
285 GW_SET_CONTACT_INPUT_LINK_REQ((short) 0x0462, "Set a link from a Contact Input to a scene or product group."),
286 GW_SET_CONTACT_INPUT_LINK_CFM((short) 0x0463, "Acknowledge to GW_SET_CONTACT_INPUT_LINK_REQ."),
287 GW_REMOVE_CONTACT_INPUT_LINK_REQ((short) 0x0464, "Remove a link from a Contact Input to a scene."),
288 GW_REMOVE_CONTACT_INPUT_LINK_CFM((short) 0x0465, "Acknowledge to GW_REMOVE_CONTACT_INPUT_LINK_REQ."),
290 GW_GET_ACTIVATION_LOG_HEADER_REQ((short) 0x0500, "Request header from activation log."),
291 GW_GET_ACTIVATION_LOG_HEADER_CFM((short) 0x0501, "Confirm header from activation log."),
292 GW_CLEAR_ACTIVATION_LOG_REQ((short) 0x0502, "Request clear all data in activation log."),
293 GW_CLEAR_ACTIVATION_LOG_CFM((short) 0x0503, "Confirm clear all data in activation log."),
294 GW_GET_ACTIVATION_LOG_LINE_REQ((short) 0x0504, "Request line from activation log."),
295 GW_GET_ACTIVATION_LOG_LINE_CFM((short) 0x0505, "Confirm line from activation log."),
296 GW_ACTIVATION_LOG_UPDATED_NTF((short) 0x0506, "Confirm line from activation log."),
297 GW_GET_MULTIPLE_ACTIVATION_LOG_LINES_REQ((short) 0x0507, "Request lines from activation log."),
298 GW_GET_MULTIPLE_ACTIVATION_LOG_LINES_NTF((short) 0x0508, "Error log data from activation log."),
299 GW_GET_MULTIPLE_ACTIVATION_LOG_LINES_CFM((short) 0x0509, "Confirm lines from activation log."),
301 GW_SET_UTC_REQ((short) 0x2000, "Request to set UTC time."),
302 GW_SET_UTC_CFM((short) 0x2001, "Acknowledge to GW_SET_UTC_REQ."),
303 GW_RTC_SET_TIME_ZONE_REQ((short) 0x2002, "Set time zone and daylight savings rules."),
304 GW_RTC_SET_TIME_ZONE_CFM((short) 0x2003, "Acknowledge to GW_RTC_SET_TIME_ZONE_REQ."),
305 GW_GET_LOCAL_TIME_REQ((short) 0x2004,
306 "Request the local time based on current time zone and daylight savings rules."),
307 GW_GET_LOCAL_TIME_CFM((short) 0x2005, "Acknowledge to GW_RTC_SET_TIME_ZONE_REQ."),
308 GW_PASSWORD_ENTER_REQ((short) 0x3000, "Enter password to authenticate request"),
309 GW_PASSWORD_ENTER_CFM((short) 0x3001, "Acknowledge to GW_PASSWORD_ENTER_REQ"),
310 GW_PASSWORD_CHANGE_REQ((short) 0x3002, "Request password change."),
311 GW_PASSWORD_CHANGE_CFM((short) 0x3003, "Acknowledge to GW_PASSWORD_CHANGE_REQ."),
312 GW_PASSWORD_CHANGE_NTF((short) 0x3004,
313 "Acknowledge to GW_PASSWORD_CHANGE_REQ. Broadcasted to all connected clients."),
319 private CommandNumber command;
320 private String description;
322 // Reverse-lookup map for getting a Command from an TypeId
323 private static final Map<Short, Command> LOOKUPTYPEID2ENUM = Stream.of(Command.values())
324 .collect(Collectors.toMap(Command::getShort, Function.identity()));
328 private Command(short typeId, String description) {
329 this.command = new CommandNumber(typeId);
330 this.description = description;
333 // Class access methods
335 public CommandNumber getCommand() {
339 public short getShort() {
340 return command.toShort();
343 public String getDescription() {
347 public static Command get(short thisTypeId) {
348 if (LOOKUPTYPEID2ENUM.containsKey(thisTypeId)) {
349 return LOOKUPTYPEID2ENUM.get(thisTypeId);
351 return Command.UNDEFTYPE;