Class ItemChangedEvent

java.lang.Object
de.hybris.platform.cockpit.events.impl.AbstractCockpitEvent
de.hybris.platform.cockpit.events.impl.ItemChangedEvent
All Implemented Interfaces:
CockpitEvent

public class ItemChangedEvent extends AbstractCockpitEvent
ItemChangedEvent is used to notify interested parties that an item has changed.
  • Constructor Details

    • ItemChangedEvent

      public ItemChangedEvent(Object source, TypedObject item, Collection<? extends PropertyDescriptor> properties)
      Creates a new ItemChangedEvent.
      Parameters:
      source - source of this event
      item - the changed item
      properties - the changed properties
    • ItemChangedEvent

      public ItemChangedEvent(Object source, TypedObject item, Collection<? extends PropertyDescriptor> properties, Map<String,? extends Object> params)
      Creates a new ItemChangedEvent.
      Parameters:
      source - source of this event
      item - the changed item
      properties - the changed properties of the item
      params - custom parameters
    • ItemChangedEvent

      public ItemChangedEvent(Object source, TypedObject item, Collection<? extends PropertyDescriptor> properties, ItemChangedEvent.ChangeType changeType)
      Creates a new ItemChangedEvent.
      Parameters:
      source - source of this event
      item - the changed item
      properties - the changed properties
      changeType - type of the item change
    • ItemChangedEvent

      public ItemChangedEvent(Object source, TypedObject item, Collection<? extends PropertyDescriptor> properties, ItemChangedEvent.ChangeType changeType, Map<String,? extends Object> params)
      Creates a new ItemChangedEvent.
      Parameters:
      source - source of this event
      item - the changed item
      properties - the changed properties
      changeType - the type of change
      params - custom parameters
  • Method Details

    • getItem

      public TypedObject getItem()
      Returns the item which has been changed.

      Note: Always returns non null.

      Returns:
      the item which has been changed
    • getProperties

      public Set<PropertyDescriptor> getProperties()
      Returns the properties which have changed or null if all need to be reloaded.
      Returns:
      the changed properties or null
    • getChangeType

      public ItemChangedEvent.ChangeType getChangeType()
      Returns type of the item change.
      Returns:
      type of the item change
    • getParameters

      public Map<String,Object> getParameters()
      Returns the custom parameters of this event.
      Returns:
      this event's custom parameters