Search in sources :

Example 1 with RFZoneHandler

use of org.openhab.binding.alarmdecoder.internal.handler.RFZoneHandler in project openhab-addons by openhab.

the class AlarmDecoderHandlerFactory method createHandler.

// Marked as Nullable only to fix incorrect redundant null check complaints from null annotations
@Override
@Nullable
protected ThingHandler createHandler(Thing thing) {
    ThingTypeUID thingTypeUID = thing.getThingTypeUID();
    if (THING_TYPE_IPBRIDGE.equals(thingTypeUID)) {
        IPBridgeHandler bridgeHandler = new IPBridgeHandler((Bridge) thing);
        registerDiscoveryService(bridgeHandler);
        return bridgeHandler;
    } else if (THING_TYPE_SERIALBRIDGE.equals(thingTypeUID)) {
        SerialBridgeHandler bridgeHandler = new SerialBridgeHandler((Bridge) thing, serialPortManager);
        registerDiscoveryService(bridgeHandler);
        return bridgeHandler;
    } else if (THING_TYPE_ZONE.equals(thingTypeUID)) {
        return new ZoneHandler(thing);
    } else if (THING_TYPE_RFZONE.equals(thingTypeUID)) {
        return new RFZoneHandler(thing);
    } else if (THING_TYPE_VZONE.equals(thingTypeUID)) {
        return new VZoneHandler(thing);
    } else if (THING_TYPE_KEYPAD.equals(thingTypeUID)) {
        return new KeypadHandler(thing);
    } else if (THING_TYPE_LRR.equals(thingTypeUID)) {
        return new LRRHandler(thing);
    }
    return null;
}
Also used : SerialBridgeHandler(org.openhab.binding.alarmdecoder.internal.handler.SerialBridgeHandler) LRRHandler(org.openhab.binding.alarmdecoder.internal.handler.LRRHandler) RFZoneHandler(org.openhab.binding.alarmdecoder.internal.handler.RFZoneHandler) VZoneHandler(org.openhab.binding.alarmdecoder.internal.handler.VZoneHandler) ThingTypeUID(org.openhab.core.thing.ThingTypeUID) KeypadHandler(org.openhab.binding.alarmdecoder.internal.handler.KeypadHandler) IPBridgeHandler(org.openhab.binding.alarmdecoder.internal.handler.IPBridgeHandler) Bridge(org.openhab.core.thing.Bridge) RFZoneHandler(org.openhab.binding.alarmdecoder.internal.handler.RFZoneHandler) ZoneHandler(org.openhab.binding.alarmdecoder.internal.handler.ZoneHandler) VZoneHandler(org.openhab.binding.alarmdecoder.internal.handler.VZoneHandler) Nullable(org.eclipse.jdt.annotation.Nullable)

Aggregations

Nullable (org.eclipse.jdt.annotation.Nullable)1 IPBridgeHandler (org.openhab.binding.alarmdecoder.internal.handler.IPBridgeHandler)1 KeypadHandler (org.openhab.binding.alarmdecoder.internal.handler.KeypadHandler)1 LRRHandler (org.openhab.binding.alarmdecoder.internal.handler.LRRHandler)1 RFZoneHandler (org.openhab.binding.alarmdecoder.internal.handler.RFZoneHandler)1 SerialBridgeHandler (org.openhab.binding.alarmdecoder.internal.handler.SerialBridgeHandler)1 VZoneHandler (org.openhab.binding.alarmdecoder.internal.handler.VZoneHandler)1 ZoneHandler (org.openhab.binding.alarmdecoder.internal.handler.ZoneHandler)1 Bridge (org.openhab.core.thing.Bridge)1 ThingTypeUID (org.openhab.core.thing.ThingTypeUID)1