2 * Copyright (c) 2010-2023 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.ihc.internal.ws.services;
15 import org.openhab.binding.ihc.internal.ws.datatypes.WSSystemInfo;
16 import org.openhab.binding.ihc.internal.ws.exeptions.IhcExecption;
17 import org.openhab.binding.ihc.internal.ws.http.IhcConnectionPool;
20 * Class to handle IHC / ELKO LS Controller's configuration service.
22 * Controller service is used to fetch system information from the controller.
24 * @author Pauli Anttila - Initial contribution
26 public class IhcConfigurationService extends IhcBaseService {
28 public IhcConfigurationService(String host, int timeout, IhcConnectionPool ihcConnectionPool) {
29 super(ihcConnectionPool, timeout, host, "ConfigurationService");
33 * Query system information from the controller.
35 * @return system information.
36 * @throws IhcExecption
38 public synchronized WSSystemInfo getSystemInfo() throws IhcExecption {
39 String response = sendSoapQuery("getSystemInfo", EMPTY_QUERY);
40 return new WSSystemInfo().parseXMLData(response);