Package org.openhab.core.thing.events
Class ChannelDescriptionChangedEvent
java.lang.Object
org.openhab.core.events.AbstractEvent
org.openhab.core.thing.events.ChannelDescriptionChangedEvent
- All Implemented Interfaces:
Event
ChannelDescriptionChangedEvents will be delivered through the openHAB event bus if the
CommandDescription or StateDescription of a channel has changed. Instances must be created with the
ThingEventFactory.- Author:
- Christoph Weitkamp - Initial contribution
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enum -
Field Summary
FieldsFields inherited from class org.openhab.core.events.AbstractEvent
ACTOR_SEPARATOR, DELEGATION_SEPARATOR -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedChannelDescriptionChangedEvent(String topic, String payload, ChannelDescriptionChangedEvent.CommonChannelDescriptionField field, ChannelUID channelUID, Set<String> linkedItemNames, String value, @Nullable String oldValue) Creates a new instance. -
Method Summary
Methods inherited from class org.openhab.core.events.AbstractEvent
buildDelegatedSource, buildDelegatedSource, buildSource, equals, getPayload, getSource, getTopic, hashCode
-
Field Details
-
TYPE
The channel description changed event type.
-
-
Constructor Details
-
ChannelDescriptionChangedEvent
protected ChannelDescriptionChangedEvent(String topic, String payload, ChannelDescriptionChangedEvent.CommonChannelDescriptionField field, ChannelUID channelUID, Set<String> linkedItemNames, String value, @Nullable String oldValue) Creates a new instance.- Parameters:
topic- the topicpayload- the payloadfield- the changed fieldchannelUID- theChannelUIDlinkedItemNames- aSetof linked item namesvalue- the new value (represented as JSON string)oldValue- the old value represented as JSON string)
-
-
Method Details
-
getType
Description copied from interface:EventGets the event type.- Returns:
- the event type
-
getField
Gets the changed field.- Returns:
- the changed field
-
getChannelUID
Gets theChannelUID.- Returns:
- the
ChannelUID
-
getLinkedItemNames
Gets the linked item names.- Returns:
- a
Setof linked item names
-
getValue
Gets the new value (represented as JSON string).- Returns:
- the new value.
-
getOldValue
Gets the old value (represented as JSON string).- Returns:
- the old value.
-
toString
-