<parameter name="gems" type="text" required="false" groupName="gems">
<label>Ruby Gems</label>
<description><![CDATA[A comma separated list of Ruby Gems to install. Versions may be constrained by separating with an
- <tt>=</tt> and then the standard RubyGems version constraint, such as "<tt>openhab-scripting=~>5.0</tt>".
+ <tt>=</tt> and then the standard RubyGems version constraint, such as "<tt>openhab-scripting=~>5.0</tt>".
]]></description>
<default>openhab-scripting=~>5.0.0</default>
</parameter>
private record ConfigurationChannel(String id, String typeId, String itemType) {
}
- private final static List<ConfigurationChannel> channels = new ArrayList<ConfigurationChannel>() {
+ private static final List<ConfigurationChannel> CHANNELS = new ArrayList<ConfigurationChannel>() {
{
add(new ConfigurationChannel(CHANNEL_COUNTRY_CODE, CHANNEL_COUNTRY_CODE, "String"));
add(new ConfigurationChannel(CHANNEL_PM_STANDARD, CHANNEL_PM_STANDARD, "String"));
}
};
- private final static Logger logger = LoggerFactory.getLogger(DynamicChannelHelper.class);
+ private static final Logger logger = LoggerFactory.getLogger(DynamicChannelHelper.class);
public static ThingBuilder updateThingWithConfigurationChannels(Thing thing, ThingBuilder builder) {
- for (ConfigurationChannel channel : channels) {
+ for (ConfigurationChannel channel : CHANNELS) {
addLocalConfigurationChannel(thing, builder, channel);
}
import org.openhab.binding.astro.internal.calc.SunCalc;
import org.openhab.binding.astro.internal.job.DailyJobSun;
import org.openhab.binding.astro.internal.job.Job;
-import org.openhab.binding.astro.internal.model.*;
+import org.openhab.binding.astro.internal.model.Planet;
+import org.openhab.binding.astro.internal.model.Position;
+import org.openhab.binding.astro.internal.model.Radiation;
+import org.openhab.binding.astro.internal.model.Range;
+import org.openhab.binding.astro.internal.model.Sun;
+import org.openhab.binding.astro.internal.model.SunPhaseName;
import org.openhab.core.i18n.TimeZoneProvider;
import org.openhab.core.scheduler.CronScheduler;
import org.openhab.core.thing.Thing;
// refresh then every 3 hours, if the last refresh was more than an hour ago
if (now.getHour() % 3 == 0 && lastRefresh.getEpochSecond() < now.minusHours(1).toEpochSecond()) {
-
// update the last refresh time
lastRefresh = Instant.now();
@BeforeEach
public void setUp() throws IllegalArgumentException, IllegalAccessException {
-
when(timeZoneProviderMock.getTimeZone()).thenReturn(ZoneId.of("GMT+2"));
when(bridgeMock.getUID()).thenReturn(BRIDGE_UID);
@BeforeEach
public void setUp() throws IOException, IllegalArgumentException, IllegalAccessException, AwattarApiException {
-
// mock the API response
try (InputStream inputStream = AwattarBridgeHandlerTest.class.getResourceAsStream("api_response.json")) {
SortedSet<AwattarPrice> result = new TreeSet<>(Comparator.comparing(AwattarPrice::timerange));
* The {@link AirthingsWaveGen1Handler} is responsible for handling commands, which are
* sent to one of the channels.
*
- * @author Davy Wong - Added Airthings Wave Gen 1 support
+ * @author Davy Wong - initial contribution, added Airthings Wave Gen 1 support
*/
@NonNullByDefault
public class AirthingsWaveGen1Handler extends AbstractAirthingsHandler {
// unsupported
break;
}
-
}
return 0;
}
/**
* The {@link BluetoothChannelUtils} contains utility functions used by the GattChannelHandler
*
- * @author Vlad Kolotov - Original author
+ * @author Vlad Kolotov - Initial contribution
* @author Connor Petty - Modified for openHAB use
*/
@NonNullByDefault
case SINT:
case FLOAT_IEE754:
case FLOAT_IEE11073:
- BluetoothUnit unit = BluetoothUnit.findByType(field.getUnit());
- if (unit != null) {
- // TODO
- // return "Number:" + unit.getUnit().getDimension();
- }
+ // BluetoothUnit unit = BluetoothUnit.findByType(field.getUnit());
+ // if (unit != null) {
+ // TODO
+ // return "Number:" + unit.getUnit().getDimension();
+ // }
return "Number";
case UTF8S:
case UTF16S:
if (decimalType != null) {
try {
return field.getEnumeration(new BigInteger(decimalType.toString()));
- } catch (NumberFormatException ex) {
+ } catch (NumberFormatException ignored) {
// do nothing
}
}
/**
* {@link CharacteristicChannelTypeProvider} that provides channel types for dynamically discovered characteristics.
*
- * @author Vlad Kolotov - Original author
+ * @author Vlad Kolotov - Initial contribution
* @author Connor Petty - Modified for openHAB use.
*/
@NonNullByDefault
* Driver for the CM11 X10 interface.
*
*
- * @author Anthony Green - Original code
+ * @author Anthony Green - Initial contribution
* @author Bob Raker - updates to setClock code, adapted code for use in openHAB2
* @see <a href="http://www.heyu.org/docs/protocol.txt">CM11 Protocol specification</a>
* @see <a href="http://www.rxtx.org">RXTX Serial API for Java</a>
.withBridge(bridgeUID).withLabel(scene.getSceneName()).build();
thingDiscovered(discoveryResult);
-
} else {
logger.debug("discovered unsupported scene: name '{}' with id {}", scene.getSceneName(),
scene.getID());
* For that it uses the {@link BridgeHandler} to register this class as a {@link DeviceStatusListener} to get informed
* about changes from the accompanying {@link Circuit}.
*
- * @author Michael Ochel
- * @author Matthias Siegele
+ * @author Michael Ochel - Initial contribution
+ * @author Matthias Siegele - Initial contribution
*/
public class CircuitHandler extends BaseThingHandler implements DeviceStatusListener {
* The {@link JSONApiResponseKeysEnum} contains digitalSTROM-JSON response keys.
*
* @author Alexander Betker - Initial contribution
- * @author Michael Ochel completely changed and updated only methods remained
- * @author Matthias Siegele completely changed and updated only methods remained
+ * @author Michael Ochel - completely changed and updated only methods remained
+ * @author Matthias Siegele - completely changed and updated only methods remained
*/
public enum JSONApiResponseKeysEnum {
}
private State getHeatChannel1Demand() {
- return getData().heatingChannels.size() >= 1
+ return !getData().heatingChannels.isEmpty()
? new QuantityType<>(getData().heatingChannels.get(0).getPercentageDemand(), Units.PERCENT)
: UnDefType.UNDEF;
}
}
private State getHeatChannel1DemandState() {
- return OnOffType.from(getData().heatingChannels.size() >= 1
+ return OnOffType.from(!getData().heatingChannels.isEmpty()
&& "ON".equalsIgnoreCase(getData().heatingChannels.get(0).getHeatingRelayState()));
}
}
private State getBoostedState() {
- if (getData().hotWater.size() >= 1) {
+ if (!getData().hotWater.isEmpty()) {
final HotWaterDTO firstChannel = getData().hotWater.get(0);
if (firstChannel.getOverrideTimeoutUnixTime() != null
}
private State getBoostRemainingState() {
- if (getData().hotWater.size() >= 1) {
+ if (!getData().hotWater.isEmpty()) {
final HotWaterDTO firstChannel = getData().hotWater.get(0);
final Integer overrideTimeout = firstChannel.getOverrideTimeoutUnixTime();
// call the custom handler to handle specific / composite channels which do not map 1:1 to JSON
// fields.
result.putAll(customResponseTransformer.transform(channel, value, jsonData));
-
} catch (NumberFormatException | DateTimeParseException ex) {
logger.warn("caught exception while parsing data for channel {} (value '{}'). Exception: {}",
channel.getUID().getId(), value, ex.getMessage());
if (object instanceof EmotivaAckDTO answerDto) {
// Currently not supported to revert a failed command update, just used for logging for now.
logger.trace("Processing received '{}' with '{}'", EmotivaAckDTO.class.getSimpleName(), answerDto);
-
} else if (object instanceof EmotivaBarNotifyWrapper answerDto) {
logger.trace("Processing received '{}' with '{}'", EmotivaBarNotifyWrapper.class.getSimpleName(),
emotivaUdpResponse.answer());
</channel-type>
<channel-type id="autoOFF" advanced="true">
- <item-type>Number:Duration</item-type>
+ <item-type>Number:Time</item-type>
<label>Auto Off</label>
<description>Automatically switch to off</description>
<state pattern="%d %unit%"/>
</channel-type>
<channel-type id="delayRadioOFF" advanced="true">
- <item-type>Number:Duration</item-type>
+ <item-type>Number:Time</item-type>
<label>Delay Radio Off</label>
<description>Delay switch off by radio for given seconds</description>
<state pattern="%d %unit%"/>
check(configuration.password, "Password parameter is empty"),
check(configuration.siteName, "siteName parameter is empty"))
.filter(s -> !s.isEmpty()).collect(Collectors.joining(", "));
-
}
if (!message.isEmpty()) {
return message;
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:config-description="https://openhab.org/schemas/config-description/v1.0.0"
xsi:schemaLocation="https://openhab.org/schemas/config-description/v1.0.0
- https://openhab.org/schemas/config-description-1.0.0.xsd">
+ https://openhab.org/schemas/config-description-1.0.0.xsd">
<config-description uri="bridge-type:freeboxos:api">
<parameter name="apiDomain" type="text">
* Class representing an internet radio based on the frontier silicon chipset. Tested with "hama IR110" and Medion
* MD87180" internet radios.
*
- * @author Rainer Ostendorf
- * @author Patrick Koenemann
+ * @author Rainer Ostendorf - Initial contribution
+ * @author Patrick Koenemann - improvements
* @author Mihaela Memova - removed duplicated check for the percent value range
*/
public class FrontierSiliconRadio {
*
* This class parses this XML data and provides functions for reading and casting typical fields.
*
- * @author Rainer Ostendorf
- * @author Patrick Koenemann
+ * @author Rainer Ostendorf - Initial contribution
+ * @author Patrick Koenemann - Improvements
*
*/
public class FrontierSiliconRadioApiResult {
/**
* This class holds the http-connection and session information for controlling the radio.
*
- * @author Rainer Ostendorf
- * @author Patrick Koenemann
+ * @author Rainer Ostendorf - Initial contribution
+ * @author Patrick Koenemann - improvements
* @author Svilen Valkanov - replaced Apache HttpClient with Jetty
* @author Mihaela Memova - changed the calling of the stopHttpClient() method, fixed the hardcoded URL path, fixed the
* for loop condition part
isLoggedIn = true;
return true; // login successful :-)
}
-
} catch (Exception e) {
logger.debug("Fatal transport error: {}", e.toString());
throw new IOException(e);
/**
* Internal constants for the frontier silicon radio.
*
- * @author Markus Rathgeb - Moved the constants to separate class
+ * @author Markus Rathgeb - Initial contribution, moved the constants to separate class
*/
public class FrontierSiliconRadioConstants {
this.onlineIntervalM = onlineIntervalM != null ? onlineIntervalM : DEFAULT_ONLINE_INTERVAL_M;
startGroupePSAPolling(pollingIntervalM);
}
-
} else {
updateStatus(ThingStatus.OFFLINE, ThingStatusDetail.BRIDGE_UNINITIALIZED);
}
Charging::getRemainingTime, x -> new BigDecimal(x.getSeconds()), Units.SECOND);
updateState(CHANNEL_ELECTRIC_CHARGING_NEXTDELAYEDTIME, energy, Energy::getCharging,
Charging::getNextDelayedTime, x -> new BigDecimal(x.getSeconds()), Units.SECOND);
-
}
}
}
DeviceType deviceType = getDeviceTypeChecked(deviceId);
switch (deviceType) {
-
case MIX:
case SPA:
setTimeProgram(deviceId, deviceType,
/**
* Handles the authentication to Homematic server.
*
- * @author Christian Kittel
+ * @author Christian Kittel - Initial contribution
*/
@NonNullByDefault
public class AuthenticationHandler {
thingHandler.getGateway().setInstallMode(false, 0);
}
}
-
} catch (Exception ex) {
logger.warn("Failed to disable Homematic controller's install mode", ex);
}
*
* @param payload The data parsed from the data Json file
*/
- abstract protected void handleDataPayload(DataPayload payload);
+ protected abstract void handleDataPayload(DataPayload payload);
/**
*
*
* @param payload The data parsed from the state Json file
*/
- abstract protected void handleStatePayload(StatePayload payload);
+ protected abstract void handleStatePayload(StatePayload payload);
protected void pollState() {
final String stateResult;
private final Bundle bundle;
private final LocaleProvider localeProvider;
private final TranslationProvider translationProvider;
- private final Map<String, Resource> automationsCache = new ConcurrentHashMap<>();;
+ private final Map<String, Resource> automationsCache = new ConcurrentHashMap<>();
private final Set<String> automationScriptIds = ConcurrentHashMap.newKeySet();
private final ChannelGroupUID automationChannelGroupUID;
Resource cachedAutomation = automationsCache.get(automation.getId());
return Objects.isNull(cachedAutomation) || !automation.getName().equals(cachedAutomation.getName());
})) {
-
synchronized (automationsCache) {
automationsCache.clear();
automationsCache.putAll(automations.stream().collect(Collectors.toMap(a -> a.getId(), a -> a)));
if (channelId.equals(FIND_MY_PHONE)) {
if (command == OnOffType.ON) {
try {
-
if (deviceInformationRecord == null) {
this.logger
.debug("Can't send Find My Device request, because deviceInformationRecord is null!");
logger.warn("Parameter '{}' is not a valid command type, using default value '{}'", param, defValue);
retval = defValue;
}
-
} else {
logger.debug("Parameter '{}' is not of type String, using default value '{}'", param, defValue);
retval = defValue;
logger.trace("retransmitting msg: {}", msg);
ioStream.write(msg.getData());
}
-
}
// if rate limited, need to sleep now.
if (msg.getQuietTime() > 0) {
<state readOnly="true" pattern="%.0f %unit%"/>
</channel-type>
<channel-type id="device-local-battery-voltage">
- <item-type>Number:ElectricalPotential</item-type>
+ <item-type>Number:ElectricPotential</item-type>
<label>Battery Voltage</label>
<description>Current battery voltage</description>
<category>Energy</category>
try {
JsonObject homelistInfo = cl.getHomeList(country.trim().toLowerCase());
final HomeListDTO homelist = GSON.fromJson(homelistInfo, HomeListDTO.class);
- if (homelist != null && homelist.getHomelist() != null && homelist.getHomelist().size() > 0) {
+ if (homelist != null && homelist.getHomelist() != null && !homelist.getHomelist().isEmpty()) {
homeLists.put(country, homelist);
}
} catch (JsonSyntaxException e) {
int writeStartRelative = writeStart - pollStart;
data = new ModbusRegisterArray(allMutatedBytes[writeStartRelative * 2],
allMutatedBytes[writeStartRelative * 2 + 1]);
-
} else {
data = ModbusBitUtilities.commandToRegisters(transformedCommand, writeValueType);
}
result = applyGainTowardsItem(offsetted, gain);
} else {
result = applyGainTowardsHandler(quantityState, gain).subtract(pregainOffsetQt);
-
}
} catch (UnconvertibleException | UnsupportedOperationException e) {
logger.warn(
<br />Any other value than the above types will be interpreted as static text, in which case the actual content of the polled
value is ignored.
<br />Multiple transformations can be chained by listing each transformation on a separate line,
- or by concatenating them with "∩", for example SERVICE1(ARG1)∩SERVICE2(ARG2)]]></description>
+ or by concatenating them with "∩", for example SERVICE1(ARG1)∩SERVICE2(ARG2)]]></description>
<default>default</default>
</parameter>
<parameter name="readValueType" type="text">
<br /><br />Use "default" to communicate that no transformation is done and value should be passed as is.
<br />Use SERVICENAME(ARG) or SERVICENAME:ARG to use transformation service.
<br />Any other value than the above types will be interpreted as static text, in which case the actual content of the command
- value is ignored.
+ value is ignored.
<br />Multiple transformations can be chained by listing each transformation on a separate line,
- or by concatenating them with "∩", for example SERVICE1(ARG1)∩SERVICE2(ARG2)]]></description>
+ or by concatenating them with "∩", for example SERVICE1(ARG1)∩SERVICE2(ARG2)]]></description>
<default>default</default>
</parameter>
<parameter name="writeValueType" type="text">
<parameter name="duvThreshold" type="decimal" required="true" min="0" max="1" step="0.001">
<label>Duv Threshold</label>
<description><![CDATA[
- Duv values at or below this value on a RGBWW color control will trigger white mode at the appropriate color temperature.
+ Duv values at or below this value on a RGBWW color control will trigger white mode at the appropriate color temperature.
1 will effectively disable this feature.
See <a href="https://www.waveformlighting.com/tech/calculate-duv-from-cie-1931-xy-coordinates/">this link</a> for more information on how this is calculated.
]]>
// Only pass numeric value for QuantityType.
if (mqttCommandValue instanceof QuantityType<?> qtCommandValue) {
cValue = new DecimalType(qtCommandValue.toBigDecimal());
-
}
String commandString = mqttFormatter.getMQTTpublishValue(cValue, "%s");
Optional<String> transformedValue = outgoingTransformation.apply(commandString);
<label>Publish Online Status</label>
<default>true</default>
<description><![CDATA[
- Publish <tt>online</tt> to <tt>homeassistant/status</tt> when discovering Home Assistant
- things in order to trigger devices to publish up-to-date discovery information.
- If you also run Home Assistant <i>and</i> other services that depend on knowing if Home
- Assistant is not running, then it's possible for those services to be out-of-sync with
- the actual status of Home Assistant, and you may want to disable this.
+ Publish <tt>online</tt> to <tt>homeassistant/status</tt> when discovering Home Assistant
+ things in order to trigger devices to publish up-to-date discovery information.
+ If you also run Home Assistant <i>and</i> other services that depend on knowing if Home
+ Assistant is not running, then it's possible for those services to be out-of-sync with
+ the actual status of Home Assistant, and you may want to disable this.
]]></description>
</parameter>
// below
// The payload length (might depend on format version ) is validated by parser.parse call
throw new IllegalArgumentException("Manufacturerer data is too short");
-
}
if ((bytes[4] & 0xff) != 0xff) {
logger.debug("Data is not representing manufacturer specific bluetooth advertisement: {}",
UrlEncoded.decodeTo(encodedUrl, tokenMap, StandardCharsets.US_ASCII);
final StringBuilder codeFound = new StringBuilder();
tokenMap.forEach((key, value) -> {
- if (value.size() > 0) {
+ if (!value.isEmpty()) {
String val = value.get(0);
if (key.endsWith(CODE) && (val != null)) {
codeFound.append(val.toString());
int button = (address >> 21) & 0x07;
return leftPadWithZeros(Integer.toHexString(nikobusAddress), 6) + ":" + mapButton(button);
-
} catch (NumberFormatException e) {
return "[" + addressString + "]";
}
switch (region.toLowerCase()) {
case "napier":
return HOSTNAME + REGION_NAPIER;
-
}
return "";
}
ContentResponse response = null;
int retriesLeft = Math.max(1, config.retry);
boolean connectionSuccess = false;
- while (connectionSuccess == false && retriesLeft > 0) {
+ while (!connectionSuccess && retriesLeft > 0) {
retriesLeft--;
try {
response = withGeneralProperties(httpClient.newRequest(location))
e.getMessage());
}
}
- if (connectionSuccess == false) {
+ if (!connectionSuccess) {
throw new CommunicationApiException("Request to OpenSprinkler device failed");
}
if (response != null && response.getStatus() != HTTP_OK_CODE) {
times[1] = (short) (((BigDecimal) getConfig().get(UP_DOWN_TIME_2)).shortValue() * 10);
times[2] = (short) (((BigDecimal) getConfig().get(UP_DOWN_TIME_3)).shortValue() * 10);
times[3] = (short) (((BigDecimal) getConfig().get(UP_DOWN_TIME_4)).shortValue() * 10);
-
} else if (getThing().getThingTypeUID().equals(THING_TYPE_DIM)) {
times[0] = (((BigDecimal) getConfig().get(DIM_TIME_1)).shortValue());
times[1] = (((BigDecimal) getConfig().get(DIM_TIME_2)).shortValue());
connect();
}
}
-
} catch (InterruptedException e) {
logger.debug("Interrupting thread.");
Thread.currentThread().interrupt();
.collect(Collectors.joining(", "));
throw new IOException(
"Serial port with name " + portName + " does not exist. Available port names: " + availablePorts);
-
}
try {
bridgePending("Waiting for Qbus client to come online");
return;
}
-
}
}
}
try {
while (!Thread.currentThread().isInterrupted() && ((qMessage = reader.readLine()) != null)) {
readMessage(qMessage);
-
}
} catch (IOException e) {
if (!listenerStopped) {
}
if ((writer == null) || (writer.checkError())) {
logger.warn("Error resending message");
-
}
}
}
throw new IOException("Cannot read from socket, reader not connected.");
}
readMessage(reader.readLine());
-
} else {
QbusBridgeHandler handler = bridgeCallBack;
if (handler != null) {
if (handler != null) {
handler.bridgeOnline();
}
-
} else {
if (handler != null) {
handler.bridgeOffline(ThingStatusDetail.CONFIGURATION_ERROR, "No serial nr defined");
* RFXCOM data class for energy message.
*
* @author Unknown - Initial contribution
- * @author Pauli Anttila
+ * @author Pauli Anttila - Migrated to OH2
*/
public class RFXComEnergyMessage extends RFXComBatteryDeviceMessage<RFXComEnergyMessage.SubType> {
* RFXCOM data class for control message.
*
* @author Pauli Anttila - Initial contribution
- * @author Mike Jagdis
+ * @author Mike Jagdis - Improvements
*/
public class RFXComInterfaceControlMessage extends RFXComBaseMessage {
private byte[] data = new byte[14];
* RFXCOM data class for lighting1 message. See X10, ARC, etc..
*
* @author Evert van Es, Cycling Engineer - Initial contribution
- * @author Pauli Anttila
+ * @author Pauli Anttila - Migrated to OH2
*/
public class RFXComLighting1Message extends RFXComDeviceMessageImpl<RFXComLighting1Message.SubType> {
* RFXCOM data class for lighting5 message.
*
* @author Paul Hampson, Neil Renaud - Initial contribution
- * @author Pauli Anttila
+ * @author Pauli Anttila - Migrated to OH2
* @author Martin van Wingerden - added support for IT and some other subtypes
*/
public class RFXComLighting5Message extends RFXComDeviceMessageImpl<RFXComLighting5Message.SubType> {
/**
* RFXCOM data class for raw messages.
*
- * @author James Hewitt-Thomas - New addition to the PRO RFXCom firmware
+ * @author James Hewitt-Thomas - Initial contribution, new addition to the PRO RFXCom firmware
*/
public class RFXComRawMessage extends RFXComDeviceMessageImpl<RFXComRawMessage.SubType> {
* (i.e. X10 Security, Visonic PowerCode, Meiantech, etc.)
*
* @author David Kalff - Initial contribution
- * @author Pauli Anttila
+ * @author Pauli Anttila - Improvements
*/
public class RFXComSecurity1Message extends RFXComBatteryDeviceMessage<RFXComSecurity1Message.SubType> {
/**
* RFXCOM data class for UV and temperature message.
*
- * @author Damien Servant - OpenHAB1 version
+ * @author Damien Servant - Initial contribution, OpenHAB1 version
* @author Mike Jagdis - Initial contribution, OpenHAB2 version
*/
public class RFXComUVMessage extends RFXComBatteryDeviceMessage<RFXComUVMessage.SubType> {
/**
* Test for RFXCom-binding
*
- * @author James Hewitt-Thomas - New addition to the PRO RFXCom firmware
+ * @author James Hewitt-Thomas - Initial contribution, new addition to the PRO RFXCom firmware
*/
@NonNullByDefault
public class RFXComRawMessageTest {
availablePorts);
updateStatus(ThingStatus.OFFLINE, ThingStatusDetail.CONFIGURATION_ERROR, description);
return;
-
}
// initialize serial port
Thread.sleep(sleep);
} catch (InterruptedException e) {
}
-
}
} catch (InterruptedIOException e) {
Thread.currentThread().interrupt();
<?xml version="1.0" encoding="UTF-8"?>
<thing:thing-descriptions bindingId="salus"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:thing="http://eclipse.org/smarthome/schemas/thing-description/v1.0.0"
- xsi:schemaLocation="http://eclipse.org/smarthome/schemas/thing-description/v1.0.0
- org.eclipse.smarthome.thing-description.xsd">
+ xmlns:thing="https://openhab.org/schemas/thing-description/v1.0.0"
+ xsi:schemaLocation="https://openhab.org/schemas/thing-description/v1.0.0 https://openhab.org/schemas/thing-description-1.0.0.xsd">
<bridge-type id="salus-aws-bridge">
<label>AWS Salus Cloud</label>
<?xml version="1.0" encoding="UTF-8"?>
<thing:thing-descriptions bindingId="salus"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:thing="http://eclipse.org/smarthome/schemas/thing-description/v1.0.0"
- xsi:schemaLocation="http://eclipse.org/smarthome/schemas/thing-description/v1.0.0
- org.eclipse.smarthome.thing-description.xsd">
+ xmlns:thing="https://openhab.org/schemas/thing-description/v1.0.0"
+ xsi:schemaLocation="https://openhab.org/schemas/thing-description/v1.0.0 https://openhab.org/schemas/thing-description-1.0.0.xsd">
<bridge-type id="salus-cloud-bridge">
<label>Salus Cloud</label>
<state readOnly="true"/>
</channel-type>
<channel-type id="generic-input-number-channel">
- <item-type>Number:Dimensionsless</item-type>
+ <item-type>Number:Dimensionless</item-type>
<label>Generic Number Input</label>
<description>
This channel type represents a generic input.
private static final String HTTP_ENDPOINT_V2 = "/api/v2/";
// common Samsung TV remote control ports
- private final static List<Integer> PORTS = List.of(55000, 1515, 7001, 15500);
+ private static final List<Integer> PORTS = List.of(55000, 1515, 7001, 15500);
private final Logger logger = LoggerFactory.getLogger(SamsungTvHandler.class);
@NonNullByDefault({})
public class TVProperties {
class Device {
- boolean FrameTVSupport;
- boolean GamePadSupport;
- boolean ImeSyncedSupport;
- String OS;
- String PowerState;
- boolean TokenAuthSupport;
- boolean VoiceSupport;
+ boolean frameTVSupport;
+ boolean gamePadSupport;
+ boolean imeSyncedSupport;
+ String oS;
+ String powerState;
+ boolean tokenAuthSupport;
+ boolean voiceSupport;
String countryCode;
String description;
String firmwareVersion;
String isSupport;
public boolean getFrameTVSupport() {
- return Optional.ofNullable(device).map(a -> a.FrameTVSupport).orElse(false);
+ return Optional.ofNullable(device).map(a -> a.frameTVSupport).orElse(false);
}
public boolean getTokenAuthSupport() {
- return Optional.ofNullable(device).map(a -> a.TokenAuthSupport).orElse(false);
+ return Optional.ofNullable(device).map(a -> a.tokenAuthSupport).orElse(false);
}
public String getPowerState() {
if (!getOS().isBlank()) {
- return Optional.ofNullable(device).map(a -> a.PowerState).orElse("on");
+ return Optional.ofNullable(device).map(a -> a.powerState).orElse("on");
}
return "off";
}
public String getOS() {
- return Optional.ofNullable(device).map(a -> a.OS).orElse("");
+ return Optional.ofNullable(device).map(a -> a.oS).orElse("");
}
public String getWifiMac() {
public String fetchPowerState() {
logger.trace("{}: fetching TV Power State", host);
TVProperties properties = fetchTVProperties(0, 2);
- String PowerState = properties.getPowerState();
- setPowerState("on".equals(PowerState));
- logger.debug("{}: PowerState is: {}", host, PowerState);
- return PowerState;
+ String powerState = properties.getPowerState();
+ setPowerState("on".equals(powerState));
+ logger.debug("{}: PowerState is: {}", host, powerState);
+ return powerState;
}
public boolean handleCommand(String channel, Command command, int ms) {
* @return true if service restated or created, false otherwise
*/
private synchronized boolean createService(String type, String udn) {
-
Optional<SamsungTvService> service = findServiceInstance(type);
if (service.isPresent()) {
@Test
public void testCaseInsensitiveMacAddress() throws IOException {
-
final PodDetailsDTO rsp = wireHelper.deSerializeResponse("/get_pod_details_response.json", PodDetailsDTO.class);
SensiboSky sky = new SensiboSky(rsp);
}
callback.onError(Objects.requireNonNullElse(failure, "Unknown error"));
} else {
-
callback.onResponse(Objects.requireNonNull(getContentAsString()));
}
}
if ("----".equals(value.getAsString())) {
return new DateTimeType(ZonedDateTime.now(this.timeZoneProvider.getTimeZone()));
} else {
-
- if (unit.equals("h:m")) {
+ if ("h:m".equals(unit)) {
String st = value.getAsString();
String[] parts = st.split(":");
int h = Integer.parseInt(parts[0]);
Unit<Time> targetUnit = Units.MINUTE;
return new QuantityType<>(h * 60 + m, targetUnit);
- } else if (unit.equals("m:s")) {
+ } else if ("m:s".equals(unit)) {
String st = value.getAsString();
String[] parts = st.split(":");
int m = Integer.parseInt(parts[0]);
Unit<Time> targetUnit = Units.SECOND;
return new QuantityType<>(m * 60 + s, targetUnit);
- } else if (unit.equals("h")) {
+ } else if ("h".equals(unit)) {
int val = Integer.parseInt(value.getAsString());
Unit<Time> targetUnit = Units.HOUR;
return df.format(dt);
}
}
-
} catch (Exception ex) {
}
return "unknown";
} catch (ConverterException ex) {
logger.warn("{}, for uid: {}, please check the item type", ex.getMessage(), uid);
}
-
}
}
logger.trace("Write request response: {} ", response);
}
-
} else {
logger.debug("Failed to get converted state from datapoint '{}'", dp);
}
detailsResolved = true;
return;
}
-
}
if (desc != null) {
for (SiemensHvacMetadata child : childs) {
generateThingsType(child, groupTypes, menu);
}
-
}
-
}
tt = createThingType(device, groupTypes);
groupTypes.add(groupType);
}
}
-
}
}
}
idx++;
-
}
}
}
lcHvacConnector.resetSessionId(null, false);
lcHvacConnector.resetSessionId(null, true);
}
-
- } catch (
-
- Exception e) {
+ } catch (Exception e) {
logger.error("siemensHvac:ResolveDpt:Error during dp reading: {}", e.getLocalizedMessage());
// Reset sessionId so we redone _auth on error
}
lcDevices.add(deviceObj);
}
-
} catch (Exception e) {
logger.error("siemensHvac:ResolveDpt:Error during dp reading: {}", e.getLocalizedMessage());
// Reset sessionId so we redone _auth on error
child.setDptId(dptId);
}
}
-
}
}
}
}
});
}
-
}
}
}
} catch (IOException ioe) {
logger.warn("Couldn't read Siemens MetaData information from file '{}'.", file.getAbsolutePath());
-
}
}
os.flush();
}
}
-
} catch (IOException ioe) {
logger.warn("Couldn't write Siemens MetaData information to file '{}'.", file.getAbsolutePath());
-
}
}
"Session request auth was unsuccessful in _doAuth(), please verify login parameters");
}
}
-
}
}
}
return resultObj;
}
}
-
}
return null;
} catch (SiemensHvacException ex) {
logger.debug("error unregistring handler: {}", handler);
}
-
}
}
mayRetry);
return;
}
-
} else {
logger.debug("error(5): invalid response from gateway, missing Result entry");
hvacConnector.onError(result.getRequest(), requestHandler, ErrorSource.ErrorBridge, mayRetry);
State state = solarMaxData.getDataDateTime();
logger.debug("Update channel state: {} - {}", channelId, state);
updateState(channel.getUID(), state);
-
} else {
// must be somthing to collect from the device, so...
if (solarMaxData.has(SolarMaxCommandKey.valueOf(channelId))) {
</channel-type>
<channel-type id="co2_concentration">
- <item-type>Number:DimensionLess</item-type>
+ <item-type>Number:Dimensionless</item-type>
<label>CO2 concentration</label>
<description>A CO2 sensor carbon dioxide concentration in ppm</description>
<state readOnly="true" pattern="%d %unit%"/>
</channel-type>
<channel-type id="noise">
- <item-type>Number:DimensionLess</item-type>
+ <item-type>Number:Dimensionless</item-type>
<label>Noise</label>
<description>A noise sensor noise in decibel</description>
<state readOnly="true" pattern="%d %unit%"/>
if (device.manufacturer.toUpperCase(Locale.ENGLISH).contains(SONY)
&& device.type.toUpperCase(Locale.ENGLISH).contains(TYPE_PROJECTOR) && !device.macAddress.isBlank()
&& !device.ipAddress.isBlank()) {
-
logger.debug("Sony projector with mac {} found at {}", device.macAddress, device.ipAddress);
return new ThingUID(THING_TYPE_ETHERNET, device.macAddress);
}
}
} catch (NumberFormatException ignore) {
}
-
}
}
}
* Returns the wind direction based on degree.
*/
public static WindDirections getWindDirection(int degree) {
-
double b = Math.floor((degree + (STEP / 2.0)) / STEP);
return values()[(int) (b % values().length)];
}
}
updateStatus(ThingStatus.OFFLINE, ThingStatusDetail.COMMUNICATION_ERROR,
"Error processing data: " + e.getMessage());
-
} catch (RuntimeException e) {
// we catch runtime exceptions here to prevent the receiving thread to stop accidentally if
// something like an IllegalStateException or NumberFormatExceptions are thrown. This indicates a
* This class handles analog values as used in the analog message.
*
* @author Timo Wendt - Initial contribution
- * @author Wolfgang Klimt
+ * @author Wolfgang Klimt - Improvements
* @author Christian Niessner - Ported to OpenHAB2
*/
@NonNullByDefault
}
public void deleteZoneOverlay(Long homeId, Long zoneId) throws IOException, ApiException {
-
// verify the required parameter 'homeId' is set
if (homeId == null) {
throw new ApiException(400, "Missing the required parameter 'homeId' when calling deleteZoneOverlay");
}
public HomeState homeState(Long homeId) throws IOException, ApiException {
-
// verify the required parameter 'homeId' is set
if (homeId == null) {
throw new ApiException(400, "Missing the required parameter 'homeId' when calling homeState");
}
public List<MobileDevice> listMobileDevices(Long homeId) throws IOException, ApiException {
-
// verify the required parameter 'homeId' is set
if (homeId == null) {
throw new ApiException(400, "Missing the required parameter 'homeId' when calling listMobileDevices");
}
public List<Zone> listZones(Long homeId) throws IOException, ApiException {
-
// verify the required parameter 'homeId' is set
if (homeId == null) {
throw new ApiException(400, "Missing the required parameter 'homeId' when calling listZones");
}
public HomeInfo showHome(Long homeId) throws IOException, ApiException {
-
// verify the required parameter 'homeId' is set
if (homeId == null) {
throw new ApiException(400, "Missing the required parameter 'homeId' when calling showHome");
}
public User showUser() throws IOException, ApiException {
-
startHttpClient(CLIENT);
// create path and map variables
}
public GenericZoneCapabilities showZoneCapabilities(Long homeId, Long zoneId) throws IOException, ApiException {
-
// verify the required parameter 'homeId' is set
if (homeId == null) {
throw new ApiException(400, "Missing the required parameter 'homeId' when calling showZoneCapabilities");
}
public OverlayTemplate showZoneDefaultOverlay(Long homeId, Long zoneId) throws IOException, ApiException {
-
// verify the required parameter 'homeId' is set
if (homeId == null) {
throw new ApiException(400, "Missing the required parameter 'homeId' when calling showZoneDefaultOverlay");
}
public Zone showZoneDetails(Long homeId, Long zoneId) throws IOException, ApiException {
-
// verify the required parameter 'homeId' is set
if (homeId == null) {
throw new ApiException(400, "Missing the required parameter 'homeId' when calling showZoneDetails");
}
public Overlay showZoneOverlay(Long homeId, Long zoneId) throws IOException, ApiException {
-
// verify the required parameter 'homeId' is set
if (homeId == null) {
throw new ApiException(400, "Missing the required parameter 'homeId' when calling showZoneOverlay");
}
public ZoneState showZoneState(Long homeId, Long zoneId) throws IOException, ApiException {
-
// verify the required parameter 'homeId' is set
if (homeId == null) {
throw new ApiException(400, "Missing the required parameter 'homeId' when calling showZoneState");
}
public void updatePresenceLock(Long homeId, HomePresence json) throws IOException, ApiException {
-
// verify the required parameter 'homeId' is set
if (homeId == null) {
throw new ApiException(400, "Missing the required parameter 'homeId' when calling updatePresenceLock");
}
public Overlay updateZoneOverlay(Long homeId, Long zoneId, Overlay json) throws IOException, ApiException {
-
// verify the required parameter 'homeId' is set
if (homeId == null) {
throw new ApiException(400, "Missing the required parameter 'homeId' when calling updateZoneOverlay");
| bbrhpjw | `Number:Energy` | Total consumed energy at high rate pricing on white days | All | Tempo |
| bbrhcjr | `Number:Energy` | Total consumed energy at low rate pricing on red days | All | Tempo |
| bbrhpjr | `Number:Energy` | Total consumed energy at high rate pricing on red days | All | Tempo |
-| pejp | `Number:Duration` | Prior notice to EJP start | All | EJP |
+| pejp | `Number:Time` | Prior notice to EJP start | All | EJP |
| demain | `String` | Following day color | All | Tempo |
### Standard TIC mode
this.isBulkRetrievalEnabled = uncheckedConfiguration.isBulkRetrievalEnabled;
this.isSequentialEnforced = uncheckedConfiguration.isSequentialEnforced;
this.isProtocolTraceEnabled = uncheckedConfiguration.isProtocolTraceEnabled;
-
}
logger.trace("VeluxBinding(constructor) done.");
}
try {
HubEauResponse stationDetails = apiHandler.discoverStations(config.id);
List<StationData> stations = stationDetails.stations;
- if (stations != null && stations.size() > 0) {
+ if (stations != null && !stations.isEmpty()) {
stationDetails.stations.stream().findFirst().ifPresent(station -> {
PointType stationLocation = new PointType(
String.format(Locale.US, "%f,%f", station.latitudeStation, station.longitudeStation));
}
var body = response.getContentAsString();
var description = gson.fromJson(body, WebThingDescription.class);
- if ((description != null) && (description.properties != null) && (description.properties.size() > 0)) {
+ if ((description != null) && (description.properties != null) && !description.properties.isEmpty()) {
if ((description.contextKeyword == null) || description.contextKeyword.trim().length() == 0) {
description.contextKeyword = "https://webthings.io/schemas";
}
* Abstract WiFi LED driver.
*
* @author Osman Basha - Initial contribution
- * @author Stefan Endrullis
- * @author Ries van Twisk
+ * @author Stefan Endrullis - Improvements
+ * @author Ries van Twisk - Improvements
*/
public abstract class AbstractWiFiLEDDriver {
* It's used for sending color or program settings and also extracting the data out of the received telegrams.
*
* @author Osman Basha - Initial contribution
- * @author Stefan Endrullis
+ * @author Stefan Endrullis - Improvements
* @author Ries van Twisk - Prevent flashes during classic driver color + white updates
*/
public class ClassicWiFiLEDDriver extends AbstractWiFiLEDDriver {
* It utilizes color fading when changing colors or turning the light on of off.
*
* @author Stefan Endrullis - Initial contribution
- * @author Ries van Twisk
+ * @author Ries van Twisk - Improvements
*/
public class FadingWiFiLEDDriver extends AbstractWiFiLEDDriver {
* sent to one of the channels.
*
* @author Osman Basha - Initial contribution
- * @author Ries van Twisk
+ * @author Ries van Twisk - Improvements
*/
public class WiFiLEDHandler extends BaseThingHandler {
/**
* Test for LEDStateDTO
*
- * @author Ries van Twisk - Prevent flashes during classic driver color + white updates
+ * @author Ries van Twisk - Initial contribution, prevent flashes during classic driver color + white updates
*/
public class LEDStateDTOTest {
XMLConstants.FEATURE_BY_YNC_TAG
.forEach((name, feature) -> checkFeature(featureNode, name, feature, state.features));
-
} else {
// on older models (RX-V3900) the Feature_Existence element does not exist
* No state will be saved in here, but in {@link DabBandState}, {@link PresetInfoState} and {@link PlayInfoState}
* instead.
*
- * @author Tomasz Maruszak - [yamaha] Tuner band selection and preset feature for dual band models (RX-S601D)
+ * @author Tomasz Maruszak - Initial contribution, [yamaha] Tuner band selection and preset feature for dual band models
+ * (RX-S601D)
*/
public class InputWithTunerDABControlXML extends AbstractInputControlXML
implements InputWithTunerBandControl, InputWithPresetControl {
}
return responseConsumer.apply(connection);
-
} finally {
if (connection != null) {
connection.disconnect();
* The zone protocol class is used to control one zone of a Yamaha receiver with HTTP/xml.
* No state will be saved in here, but in {@link ZoneControlState} instead.
*
+ * @author Tomasz Maruszak - Initial contribution, refactoring, input mapping fix, added
+ * Straight surround, volume DB fix and config improvement.
* @author David Gräff - Refactored
- * @author Eric Thill
- * @author Ben Jones
- * @author Tomasz Maruszak - Refactoring, input mapping fix, added Straight surround, volume DB fix and config
- * improvement.
+ * @author Eric Thill - Unknown
+ * @author Ben Jones - Unknown
*/
public class ZoneControlXML implements ZoneControl {
"Surr/Pgm_Sel/Straight");
logger.debug("Zone {} - adjusting command to: {}", getZone(), surroundSelStraight);
}
-
} catch (ReceivedMessageParseException | IOException e) {
logger.debug("Could not perform feature detection for RX-V3900");
}
/**
* The band state for DAB tuners.
*
- * @author Tomasz Maruszak - [yamaha] Tuner band selection and preset feature for dual band models (RX-S601D)
+ * @author Tomasz Maruszak - Initial contribution, [yamaha] Tuner band selection and preset feature for dual band models
+ * (RX-S601D)
*/
public class DabBandState implements Invalidateable {
/**
* Listener for changes to {@link DabBandState}
*
- * @author Tomasz Maruszak - [yamaha] Tuner band selection and preset feature for dual band models (RX-S601D)
+ * @author Tomasz Maruszak - Initial contribution, [yamaha] Tuner band selection and preset feature for dual band models
+ * (RX-S601D)
*/
public interface DabBandStateListener {
void dabBandUpdated(DabBandState msg);
/**
* Represent object whose state can be invalidated.
*
- * @author Tomasz Maruszak - [yamaha] Tuner band selection and preset feature for dual band models (RX-S601D)
+ * @author Tomasz Maruszak - Initial contribution, [yamaha] Tuner band selection and preset feature for dual band models
+ * (RX-S601D)
*/
public interface Invalidateable {
@NonNullByDefault
public class StateFilterProfile implements StateProfile {
- private final static String OPERATOR_NAME_PATTERN = Stream.of(StateCondition.ComparisonType.values())
+ private static final String OPERATOR_NAME_PATTERN = Stream.of(StateCondition.ComparisonType.values())
.map(StateCondition.ComparisonType::name)
// We want to match the longest operator first, e.g. `GTE` before `GT`
.sorted(Comparator.comparingInt(String::length).reversed())
// so we can have conditions against input data without needing a leading space, e.g. `GTE 0`
.collect(Collectors.joining("|", "(?:(?<=\\S)\\s+|^\\s*)(?:", ")\\s"));
- private final static String OPERATOR_SYMBOL_PATTERN = Stream.of(StateCondition.ComparisonType.values())
+ private static final String OPERATOR_SYMBOL_PATTERN = Stream.of(StateCondition.ComparisonType.values())
.map(StateCondition.ComparisonType::symbol)
// We want to match the longest operator first, e.g. `<=` before `<`
.sorted(Comparator.comparingInt(String::length).reversed()) //
.collect(Collectors.joining("|", "(?:", ")"));
- private final static Pattern EXPRESSION_PATTERN = Pattern.compile(
+ private static final Pattern EXPRESSION_PATTERN = Pattern.compile(
// - Without the non-greedy operator in the first capture group,
// it will match `Item<` when encountering `Item<>X` condition
// - Symbols may be more prevalently used, so check them first
import org.openhab.core.items.Item;
import org.openhab.core.items.ItemNotFoundException;
import org.openhab.core.items.ItemRegistry;
-import org.openhab.core.library.items.*;
-import org.openhab.core.library.types.*;
+import org.openhab.core.library.items.ContactItem;
+import org.openhab.core.library.items.DimmerItem;
+import org.openhab.core.library.items.NumberItem;
+import org.openhab.core.library.items.RollershutterItem;
+import org.openhab.core.library.items.StringItem;
+import org.openhab.core.library.items.SwitchItem;
+import org.openhab.core.library.types.DecimalType;
+import org.openhab.core.library.types.OnOffType;
+import org.openhab.core.library.types.OpenClosedType;
+import org.openhab.core.library.types.PercentType;
+import org.openhab.core.library.types.QuantityType;
+import org.openhab.core.library.types.StringType;
import org.openhab.core.library.unit.SIUnits;
import org.openhab.core.thing.link.ItemChannelLink;
import org.openhab.core.thing.profiles.ProfileCallback;
return item;
}
- private Item numberItemWithState(String itemType, String itemName, State value) {
- NumberItem item = new NumberItem(itemType, itemName, null);
- item.setState(value);
- return item;
- }
+ /*
+ * private Item numberItemWithState(String itemType, String itemName, State value) {
+ * NumberItem item = new NumberItem(itemType, itemName, null);
+ * item.setState(value);
+ * return item;
+ * }
+ */
@Test
- public void testMultipleCondition_AllMatch() throws ItemNotFoundException {
+ public void testMultipleConditionAllMatch() throws ItemNotFoundException {
when(mockContext.getConfiguration())
.thenReturn(new Configuration(Map.of("conditions", "ItemName eq 'Value', ItemName2 eq 'Value2'")));
when(mockItemRegistry.getItem("ItemName")).thenReturn(stringItemWithState("ItemName", "Value"));
}
@Test
- public void testMultipleCondition_SingleMatch() throws ItemNotFoundException {
+ public void testMultipleConditionSingleMatch() throws ItemNotFoundException {
when(mockContext.getConfiguration())
.thenReturn(new Configuration(Map.of("conditions", "ItemName eq Value, ItemName2 eq Value2")));
when(mockItemRegistry.getItem("ItemName")).thenReturn(stringItemWithState("ItemName", "Value"));
StringType s_foo = StringType.valueOf("foo");
StringType s_NULL = StringType.valueOf("NULL");
StringType s_UNDEF = StringType.valueOf("UNDEF");
- StringType s_OPEN = StringType.valueOf("OPEN");
+ // StringType s_OPEN = StringType.valueOf("OPEN");
return Stream.of( //
// We should be able to check item state is/isn't UNDEF/NULL
@MethodSource
public void testComparingInputStateWithValue(GenericItem linkedItem, State inputState, String operator,
String value, boolean expected) throws ItemNotFoundException {
-
String linkedItemName = linkedItem.getName();
when(mockContext.getConfiguration()).thenReturn(new Configuration(Map.of("conditions", operator + value)));
return this.label;
}
- /**
- * {@inheritDoc}
- */
+ // automatically inherit doc
@Override
public Locale getLocale() {
return this.locale;
* This is a TTS service implementation for Mac OS, which simply uses the "say" command from the OS.
*
* @author Kai Kreuzer - Initial contribution and API
- * @author Pauli Antilla
- * @author Kelly Davis
- * @author Laurent Garnier : Implement TTS LRU cache
+ * @author Pauli Antilla - Improvements
+ * @author Kelly Davis - Improvements
+ * @author Laurent Garnier - Implement TTS LRU cache
*/
@Component(service = TTSService.class)
@NonNullByDefault
return label;
}
- /**
- * {@inheritDoc}
- */
+ // automatically inherit doc
@Override
public Locale getLocale() {
return locale;
return label;
}
- /**
- * {@inheritDoc}
- */
+ // automatically inherit doc
@Override
public Locale getLocale() {
return locale;
return label;
}
- /**
- * {@inheritDoc}
- */
+ // automatically inherit doc
@Override
public Locale getLocale() {
return locale;
private static final String ACCEPTED_ITEM_TYPE_DATE_TIME = "DateTime";
private static final String TEST_HOSTNAME = "127.0.0.1";
private static final int TEST_PORT = 9002;
+ private static final String WRONG_HOSTNAME = "wrong.hostname";
static SimpleNTPServer timeServer;
private ChannelTypeUID channelTypeUID;
private void assertCommunicationError(String acceptedItemType) {
Configuration configuration = new Configuration();
- final String WRONG_HOSTNAME = "wrong.hostname";
if (acceptedItemType.equals(ACCEPTED_ITEM_TYPE_DATE_TIME)) {
initialize(configuration, NtpBindingConstants.CHANNEL_DATE_TIME, ACCEPTED_ITEM_TYPE_DATE_TIME, null,
WRONG_HOSTNAME);