]> git.basschouten.com Git - openhab-addons.git/blob
c17286dfba71dc5ae12f84a85e46cbb450f80e49
[openhab-addons.git] /
1 /**
2  * Copyright (c) 2010-2023 Contributors to the openHAB project
3  *
4  * See the NOTICE file(s) distributed with this work for additional
5  * information.
6  *
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
10  *
11  * SPDX-License-Identifier: EPL-2.0
12  */
13 package org.openhab.binding.herzborg.internal;
14
15 import org.eclipse.jdt.annotation.NonNullByDefault;
16 import org.openhab.core.thing.Bridge;
17 import org.openhab.core.thing.ChannelUID;
18 import org.openhab.core.thing.binding.BaseBridgeHandler;
19 import org.openhab.core.types.Command;
20
21 /**
22  * The {@link BusHandler} is a handy base class, implementing data communication with Herzborg devices.
23  *
24  * @author Pavel Fedin - Initial contribution
25  */
26 @NonNullByDefault
27 public abstract class BusHandler extends BaseBridgeHandler {
28     protected Bus bus;
29
30     public BusHandler(Bridge bridge, Bus bus) {
31         super(bridge);
32         this.bus = bus;
33     }
34
35     public Bus getBus() {
36         return bus;
37     }
38
39     @Override
40     public void handleCommand(ChannelUID channelUID, Command command) {
41         // Nothing to do here, but we have to implement it
42     }
43 }