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.mqtt.homie.internal.homie300;
15 import org.eclipse.jdt.annotation.NonNullByDefault;
16 import org.openhab.binding.mqtt.generic.ChannelStateUpdateListener;
17 import org.openhab.binding.mqtt.homie.internal.homie300.DeviceAttributes.ReadyState;
20 * Callbacks to inform about the Homie Device state, statistics changes, node layout changes.
21 * Meant to be used by the Homie thing handler.
23 * @author David Graeff - Initial contribution
26 public interface DeviceCallback extends ChannelStateUpdateListener {
28 * Called whenever the device state changed
30 * @param state The new state
32 void readyStateChanged(ReadyState state);
35 * Called, whenever a Homie node was existing before, but is not anymore.
37 * @param node The affected node class.
39 void nodeRemoved(Node node);
42 * Called, whenever a Homie property was existing before, but is not anymore.
44 * @param property The affected property class.
46 void propertyRemoved(Property property);
49 * Called, whenever a Homie node was added or changed.
51 * @param node The affected node class.
53 void nodeAddedOrChanged(Node node);
56 * Called, whenever a Homie property was added or changed.
58 * @param property The affected property class.
60 void propertyAddedOrChanged(Property property);