Package org.openhab.core.items.events
Class AbstractItemRegistryEvent
java.lang.Object
org.openhab.core.events.AbstractEvent
org.openhab.core.items.events.AbstractItemRegistryEvent
- All Implemented Interfaces:
Event
- Direct Known Subclasses:
ItemAddedEvent,ItemRemovedEvent,ItemUpdatedEvent
Abstract implementation of an item registry event which will be posted by the
ItemRegistry for added, removed
and updated items.- Author:
- Stefan Bußweiler - Initial contribution
-
Field Summary
Fields inherited from class org.openhab.core.events.AbstractEvent
ACTOR_SEPARATOR, DELEGATION_SEPARATOR -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedAbstractItemRegistryEvent(String topic, String payload, @Nullable String source, ItemDTO item) Must be called in subclass constructor to create a new item registry event. -
Method Summary
Methods inherited from class org.openhab.core.events.AbstractEvent
buildDelegatedSource, buildDelegatedSource, buildSource, equals, getPayload, getSource, getTopic, hashCode
-
Constructor Details
-
AbstractItemRegistryEvent
protected AbstractItemRegistryEvent(String topic, String payload, @Nullable String source, ItemDTO item) Must be called in subclass constructor to create a new item registry event.- Parameters:
topic- the topicpayload- the payloadsource- the sourceitem- the item data transfer object
-
-
Method Details
-
getItem
Gets the item.- Returns:
- the item
-