Class ItemStateChangedEvent

    • Field Detail

      • TYPE

        public static final String TYPE
        The item state changed event type.
      • itemState

        protected final State itemState
      • oldItemState

        protected final State oldItemState
    • Constructor Detail

      • ItemStateChangedEvent

        protected ItemStateChangedEvent​(String topic,
                                        String payload,
                                        String itemName,
                                        State newItemState,
                                        State oldItemState)
        Constructs a new item state changed event.
        Parameters:
        topic - the topic
        payload - the payload
        itemName - the item name
        newItemState - the new item state
        oldItemState - the old item state
    • Method Detail

      • getType

        public String getType()
        Description copied from interface: Event
        Gets the event type.
        Returns:
        the event type
      • getItemState

        public State getItemState()
        Gets the item state.
        Returns:
        the item state
      • getOldItemState

        public State getOldItemState()
        Gets the old item state.
        Returns:
        the old item state