Class ItemChangedEvent
- java.lang.Object
-
- de.hybris.platform.cockpit.events.impl.AbstractCockpitEvent
-
- de.hybris.platform.cockpit.events.impl.ItemChangedEvent
-
- All Implemented Interfaces:
CockpitEvent
- Direct Known Subclasses:
DeleteJobEvent
,StartStopEvent
public class ItemChangedEvent extends AbstractCockpitEvent
ItemChangedEvent
is used to notify interested parties that an item has changed.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ItemChangedEvent.ChangeType
Type of the change.
-
Constructor Summary
Constructors Constructor Description ItemChangedEvent(java.lang.Object source, TypedObject item, java.util.Collection<? extends PropertyDescriptor> properties)
Creates a newItemChangedEvent
.ItemChangedEvent(java.lang.Object source, TypedObject item, java.util.Collection<? extends PropertyDescriptor> properties, ItemChangedEvent.ChangeType changeType)
Creates a newItemChangedEvent
.ItemChangedEvent(java.lang.Object source, TypedObject item, java.util.Collection<? extends PropertyDescriptor> properties, ItemChangedEvent.ChangeType changeType, java.util.Map<java.lang.String,? extends java.lang.Object> params)
Creates a newItemChangedEvent
.ItemChangedEvent(java.lang.Object source, TypedObject item, java.util.Collection<? extends PropertyDescriptor> properties, java.util.Map<java.lang.String,? extends java.lang.Object> params)
Creates a newItemChangedEvent
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ItemChangedEvent.ChangeType
getChangeType()
Returns type of the item change.TypedObject
getItem()
Returns the item which has been changed.java.util.Map<java.lang.String,java.lang.Object>
getParameters()
Returns the custom parameters of this event.java.util.Set<PropertyDescriptor>
getProperties()
Returns the properties which have changed ornull
if all need to be reloaded.-
Methods inherited from class de.hybris.platform.cockpit.events.impl.AbstractCockpitEvent
getSource, toString
-
-
-
-
Constructor Detail
-
ItemChangedEvent
public ItemChangedEvent(java.lang.Object source, TypedObject item, java.util.Collection<? extends PropertyDescriptor> properties)
Creates a newItemChangedEvent
.- Parameters:
source
- source of this eventitem
- the changed itemproperties
- the changed properties
-
ItemChangedEvent
public ItemChangedEvent(java.lang.Object source, TypedObject item, java.util.Collection<? extends PropertyDescriptor> properties, java.util.Map<java.lang.String,? extends java.lang.Object> params)
Creates a newItemChangedEvent
.- Parameters:
source
- source of this eventitem
- the changed itemproperties
- the changed properties of the itemparams
- custom parameters
-
ItemChangedEvent
public ItemChangedEvent(java.lang.Object source, TypedObject item, java.util.Collection<? extends PropertyDescriptor> properties, ItemChangedEvent.ChangeType changeType)
Creates a newItemChangedEvent
.- Parameters:
source
- source of this eventitem
- the changed itemproperties
- the changed propertieschangeType
- type of the item change
-
ItemChangedEvent
public ItemChangedEvent(java.lang.Object source, TypedObject item, java.util.Collection<? extends PropertyDescriptor> properties, ItemChangedEvent.ChangeType changeType, java.util.Map<java.lang.String,? extends java.lang.Object> params)
Creates a newItemChangedEvent
.- Parameters:
source
- source of this eventitem
- the changed itemproperties
- the changed propertieschangeType
- the type of changeparams
- custom parameters
-
-
Method Detail
-
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 java.util.Set<PropertyDescriptor> getProperties()
Returns the properties which have changed ornull
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 java.util.Map<java.lang.String,java.lang.Object> getParameters()
Returns the custom parameters of this event.- Returns:
- this event's custom parameters
-
-