[openwebnet] refactoring to internal package (#10995)
Signed-off-by: Massimo Valla <mvcode00@gmail.com>pull/11017/head
parent
11a66e5ce8
commit
bd1d8f4980
|
@ -10,7 +10,7 @@
|
|||
*
|
||||
* SPDX-License-Identifier: EPL-2.0
|
||||
*/
|
||||
package org.openhab.binding.openwebnet;
|
||||
package org.openhab.binding.openwebnet.internal;
|
||||
|
||||
import java.util.Collection;
|
||||
import java.util.HashSet;
|
|
@ -12,16 +12,16 @@
|
|||
*/
|
||||
package org.openhab.binding.openwebnet.internal;
|
||||
|
||||
import static org.openhab.binding.openwebnet.OpenWebNetBindingConstants.ALL_SUPPORTED_THING_TYPES;
|
||||
import static org.openhab.binding.openwebnet.internal.OpenWebNetBindingConstants.ALL_SUPPORTED_THING_TYPES;
|
||||
|
||||
import org.eclipse.jdt.annotation.NonNullByDefault;
|
||||
import org.eclipse.jdt.annotation.Nullable;
|
||||
import org.openhab.binding.openwebnet.handler.OpenWebNetAutomationHandler;
|
||||
import org.openhab.binding.openwebnet.handler.OpenWebNetBridgeHandler;
|
||||
import org.openhab.binding.openwebnet.handler.OpenWebNetEnergyHandler;
|
||||
import org.openhab.binding.openwebnet.handler.OpenWebNetGenericHandler;
|
||||
import org.openhab.binding.openwebnet.handler.OpenWebNetLightingHandler;
|
||||
import org.openhab.binding.openwebnet.handler.OpenWebNetThermoregulationHandler;
|
||||
import org.openhab.binding.openwebnet.internal.handler.OpenWebNetAutomationHandler;
|
||||
import org.openhab.binding.openwebnet.internal.handler.OpenWebNetBridgeHandler;
|
||||
import org.openhab.binding.openwebnet.internal.handler.OpenWebNetEnergyHandler;
|
||||
import org.openhab.binding.openwebnet.internal.handler.OpenWebNetGenericHandler;
|
||||
import org.openhab.binding.openwebnet.internal.handler.OpenWebNetLightingHandler;
|
||||
import org.openhab.binding.openwebnet.internal.handler.OpenWebNetThermoregulationHandler;
|
||||
import org.openhab.core.thing.Bridge;
|
||||
import org.openhab.core.thing.Thing;
|
||||
import org.openhab.core.thing.ThingTypeUID;
|
||||
|
|
|
@ -27,7 +27,7 @@ import org.jupnp.model.meta.ModelDetails;
|
|||
import org.jupnp.model.meta.RemoteDevice;
|
||||
import org.jupnp.model.meta.RemoteDeviceIdentity;
|
||||
import org.jupnp.model.types.UDN;
|
||||
import org.openhab.binding.openwebnet.OpenWebNetBindingConstants;
|
||||
import org.openhab.binding.openwebnet.internal.OpenWebNetBindingConstants;
|
||||
import org.openhab.core.config.discovery.DiscoveryResult;
|
||||
import org.openhab.core.config.discovery.DiscoveryResultBuilder;
|
||||
import org.openhab.core.config.discovery.upnp.UpnpDiscoveryParticipant;
|
||||
|
|
|
@ -18,8 +18,8 @@ import java.util.Set;
|
|||
|
||||
import org.eclipse.jdt.annotation.NonNullByDefault;
|
||||
import org.eclipse.jdt.annotation.Nullable;
|
||||
import org.openhab.binding.openwebnet.OpenWebNetBindingConstants;
|
||||
import org.openhab.binding.openwebnet.handler.OpenWebNetBridgeHandler;
|
||||
import org.openhab.binding.openwebnet.internal.OpenWebNetBindingConstants;
|
||||
import org.openhab.binding.openwebnet.internal.handler.OpenWebNetBridgeHandler;
|
||||
import org.openhab.core.config.discovery.AbstractDiscoveryService;
|
||||
import org.openhab.core.config.discovery.DiscoveryResult;
|
||||
import org.openhab.core.config.discovery.DiscoveryResultBuilder;
|
||||
|
|
|
@ -22,7 +22,7 @@ import java.util.stream.Stream;
|
|||
|
||||
import org.eclipse.jdt.annotation.NonNullByDefault;
|
||||
import org.eclipse.jdt.annotation.Nullable;
|
||||
import org.openhab.binding.openwebnet.OpenWebNetBindingConstants;
|
||||
import org.openhab.binding.openwebnet.internal.OpenWebNetBindingConstants;
|
||||
import org.openhab.core.config.discovery.AbstractDiscoveryService;
|
||||
import org.openhab.core.config.discovery.DiscoveryResult;
|
||||
import org.openhab.core.config.discovery.DiscoveryResultBuilder;
|
||||
|
|
|
@ -10,9 +10,9 @@
|
|||
*
|
||||
* SPDX-License-Identifier: EPL-2.0
|
||||
*/
|
||||
package org.openhab.binding.openwebnet.handler;
|
||||
package org.openhab.binding.openwebnet.internal.handler;
|
||||
|
||||
import static org.openhab.binding.openwebnet.OpenWebNetBindingConstants.CHANNEL_SHUTTER;
|
||||
import static org.openhab.binding.openwebnet.internal.OpenWebNetBindingConstants.CHANNEL_SHUTTER;
|
||||
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Date;
|
||||
|
@ -22,7 +22,7 @@ import java.util.concurrent.TimeUnit;
|
|||
|
||||
import org.eclipse.jdt.annotation.NonNullByDefault;
|
||||
import org.eclipse.jdt.annotation.Nullable;
|
||||
import org.openhab.binding.openwebnet.OpenWebNetBindingConstants;
|
||||
import org.openhab.binding.openwebnet.internal.OpenWebNetBindingConstants;
|
||||
import org.openhab.core.config.core.Configuration;
|
||||
import org.openhab.core.library.types.PercentType;
|
||||
import org.openhab.core.library.types.StopMoveType;
|
|
@ -10,11 +10,9 @@
|
|||
*
|
||||
* SPDX-License-Identifier: EPL-2.0
|
||||
*/
|
||||
package org.openhab.binding.openwebnet.handler;
|
||||
package org.openhab.binding.openwebnet.internal.handler;
|
||||
|
||||
import static org.openhab.binding.openwebnet.OpenWebNetBindingConstants.PROPERTY_FIRMWARE_VERSION;
|
||||
import static org.openhab.binding.openwebnet.OpenWebNetBindingConstants.PROPERTY_SERIAL_NO;
|
||||
import static org.openhab.binding.openwebnet.OpenWebNetBindingConstants.THING_TYPE_ZB_GATEWAY;
|
||||
import static org.openhab.binding.openwebnet.internal.OpenWebNetBindingConstants.*;
|
||||
|
||||
import java.util.Collection;
|
||||
import java.util.Collections;
|
||||
|
@ -26,10 +24,10 @@ import java.util.concurrent.TimeUnit;
|
|||
|
||||
import org.eclipse.jdt.annotation.NonNullByDefault;
|
||||
import org.eclipse.jdt.annotation.Nullable;
|
||||
import org.openhab.binding.openwebnet.OpenWebNetBindingConstants;
|
||||
import org.openhab.binding.openwebnet.handler.config.OpenWebNetBusBridgeConfig;
|
||||
import org.openhab.binding.openwebnet.handler.config.OpenWebNetZigBeeBridgeConfig;
|
||||
import org.openhab.binding.openwebnet.internal.OpenWebNetBindingConstants;
|
||||
import org.openhab.binding.openwebnet.internal.discovery.OpenWebNetDeviceDiscoveryService;
|
||||
import org.openhab.binding.openwebnet.internal.handler.config.OpenWebNetBusBridgeConfig;
|
||||
import org.openhab.binding.openwebnet.internal.handler.config.OpenWebNetZigBeeBridgeConfig;
|
||||
import org.openhab.core.config.core.status.ConfigStatusMessage;
|
||||
import org.openhab.core.thing.Bridge;
|
||||
import org.openhab.core.thing.ChannelUID;
|
|
@ -10,9 +10,9 @@
|
|||
*
|
||||
* SPDX-License-Identifier: EPL-2.0
|
||||
*/
|
||||
package org.openhab.binding.openwebnet.handler;
|
||||
package org.openhab.binding.openwebnet.internal.handler;
|
||||
|
||||
import static org.openhab.binding.openwebnet.OpenWebNetBindingConstants.CHANNEL_POWER;
|
||||
import static org.openhab.binding.openwebnet.internal.OpenWebNetBindingConstants.CHANNEL_POWER;
|
||||
|
||||
import java.util.Set;
|
||||
import java.util.concurrent.ScheduledFuture;
|
||||
|
@ -22,7 +22,7 @@ import javax.measure.quantity.Power;
|
|||
|
||||
import org.eclipse.jdt.annotation.NonNullByDefault;
|
||||
import org.eclipse.jdt.annotation.Nullable;
|
||||
import org.openhab.binding.openwebnet.OpenWebNetBindingConstants;
|
||||
import org.openhab.binding.openwebnet.internal.OpenWebNetBindingConstants;
|
||||
import org.openhab.core.library.types.QuantityType;
|
||||
import org.openhab.core.library.unit.Units;
|
||||
import org.openhab.core.thing.ChannelUID;
|
|
@ -10,12 +10,12 @@
|
|||
*
|
||||
* SPDX-License-Identifier: EPL-2.0
|
||||
*/
|
||||
package org.openhab.binding.openwebnet.handler;
|
||||
package org.openhab.binding.openwebnet.internal.handler;
|
||||
|
||||
import java.util.Set;
|
||||
|
||||
import org.eclipse.jdt.annotation.NonNullByDefault;
|
||||
import org.openhab.binding.openwebnet.OpenWebNetBindingConstants;
|
||||
import org.openhab.binding.openwebnet.internal.OpenWebNetBindingConstants;
|
||||
import org.openhab.core.thing.ChannelUID;
|
||||
import org.openhab.core.thing.Thing;
|
||||
import org.openhab.core.thing.ThingTypeUID;
|
|
@ -10,22 +10,16 @@
|
|||
*
|
||||
* SPDX-License-Identifier: EPL-2.0
|
||||
*/
|
||||
package org.openhab.binding.openwebnet.handler;
|
||||
package org.openhab.binding.openwebnet.internal.handler;
|
||||
|
||||
import static org.openhab.binding.openwebnet.OpenWebNetBindingConstants.CHANNEL_BRIGHTNESS;
|
||||
import static org.openhab.binding.openwebnet.OpenWebNetBindingConstants.CHANNEL_SWITCH;
|
||||
import static org.openhab.binding.openwebnet.OpenWebNetBindingConstants.CHANNEL_SWITCH_01;
|
||||
import static org.openhab.binding.openwebnet.OpenWebNetBindingConstants.CHANNEL_SWITCH_02;
|
||||
import static org.openhab.binding.openwebnet.OpenWebNetBindingConstants.THING_TYPE_BUS_DIMMER;
|
||||
import static org.openhab.binding.openwebnet.OpenWebNetBindingConstants.THING_TYPE_ZB_DIMMER;
|
||||
import static org.openhab.binding.openwebnet.OpenWebNetBindingConstants.THING_TYPE_ZB_ON_OFF_SWITCH_2UNITS;
|
||||
import static org.openhab.binding.openwebnet.internal.OpenWebNetBindingConstants.*;
|
||||
|
||||
import java.util.Set;
|
||||
import java.util.concurrent.TimeUnit;
|
||||
|
||||
import org.eclipse.jdt.annotation.NonNullByDefault;
|
||||
import org.eclipse.jdt.annotation.Nullable;
|
||||
import org.openhab.binding.openwebnet.OpenWebNetBindingConstants;
|
||||
import org.openhab.binding.openwebnet.internal.OpenWebNetBindingConstants;
|
||||
import org.openhab.core.library.types.IncreaseDecreaseType;
|
||||
import org.openhab.core.library.types.OnOffType;
|
||||
import org.openhab.core.library.types.PercentType;
|
|
@ -10,14 +10,14 @@
|
|||
*
|
||||
* SPDX-License-Identifier: EPL-2.0
|
||||
*/
|
||||
package org.openhab.binding.openwebnet.handler;
|
||||
package org.openhab.binding.openwebnet.internal.handler;
|
||||
|
||||
import static org.openhab.binding.openwebnet.OpenWebNetBindingConstants.*;
|
||||
import static org.openhab.binding.openwebnet.internal.OpenWebNetBindingConstants.*;
|
||||
|
||||
import java.util.Set;
|
||||
|
||||
import org.eclipse.jdt.annotation.NonNullByDefault;
|
||||
import org.openhab.binding.openwebnet.OpenWebNetBindingConstants;
|
||||
import org.openhab.binding.openwebnet.internal.OpenWebNetBindingConstants;
|
||||
import org.openhab.core.library.types.DecimalType;
|
||||
import org.openhab.core.library.types.QuantityType;
|
||||
import org.openhab.core.library.types.StringType;
|
|
@ -10,9 +10,9 @@
|
|||
*
|
||||
* SPDX-License-Identifier: EPL-2.0
|
||||
*/
|
||||
package org.openhab.binding.openwebnet.handler;
|
||||
package org.openhab.binding.openwebnet.internal.handler;
|
||||
|
||||
import static org.openhab.binding.openwebnet.OpenWebNetBindingConstants.*;
|
||||
import static org.openhab.binding.openwebnet.internal.OpenWebNetBindingConstants.*;
|
||||
|
||||
import java.util.Map;
|
||||
import java.util.concurrent.ScheduledFuture;
|
|
@ -10,7 +10,7 @@
|
|||
*
|
||||
* SPDX-License-Identifier: EPL-2.0
|
||||
*/
|
||||
package org.openhab.binding.openwebnet.handler.config;
|
||||
package org.openhab.binding.openwebnet.internal.handler.config;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
|
@ -10,7 +10,7 @@
|
|||
*
|
||||
* SPDX-License-Identifier: EPL-2.0
|
||||
*/
|
||||
package org.openhab.binding.openwebnet.handler.config;
|
||||
package org.openhab.binding.openwebnet.internal.handler.config;
|
||||
|
||||
import org.eclipse.jdt.annotation.NonNullByDefault;
|
||||
import org.eclipse.jdt.annotation.Nullable;
|
|
@ -10,7 +10,7 @@
|
|||
*
|
||||
* SPDX-License-Identifier: EPL-2.0
|
||||
*/
|
||||
package org.openhab.binding.openwebnet.handler;
|
||||
package org.openhab.binding.openwebnet.internal.handler;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
import static org.mockito.Mockito.mock;
|
||||
|
@ -31,7 +31,8 @@ import org.slf4j.Logger;
|
|||
import org.slf4j.LoggerFactory;
|
||||
|
||||
/**
|
||||
* Test class for {@link OpenWebNetBridgeHandler#ownID} and ThingID calculation using {@link OpenWebNetBridgeHandler}
|
||||
* Test class for {@link OpenWebNetBridgeHandler#ownID} and ThingID
|
||||
* calculation using {@link OpenWebNetBridgeHandler}
|
||||
* methods: normalizeWhere(), ownIdFromWhoWhere(), ownIdFromMessage(), thingIdFromWhere()
|
||||
*
|
||||
* @author Massimo Valla - Initial contribution
|
Loading…
Reference in New Issue