Class AbstractReferenceDropHandler<DRAGGED,TARGET>

java.lang.Object
com.hybris.backoffice.cockpitng.dnd.handlers.AbstractReferenceDropHandler<DRAGGED,TARGET>
Type Parameters:
DRAGGED - dragged objects type.
TARGET - target object type.
All Implemented Interfaces:
com.hybris.cockpitng.dnd.DropHandler<DRAGGED,TARGET>
Direct Known Subclasses:
CategoryToCatalogVersionDropHandler, CategoryToCategoryDropHandler, ProductToCategoryDropHandler

public abstract class AbstractReferenceDropHandler<DRAGGED,TARGET> extends Object implements com.hybris.cockpitng.dnd.DropHandler<DRAGGED,TARGET>
Helper class facilitates implementation of drag and drop handlers. It provides ability to distinguish the type of drag and drop action performed.
See Also:
  • DragAndDropActionType
  • Constructor Details

    • AbstractReferenceDropHandler

      public AbstractReferenceDropHandler()
  • Method Details

    • handleDrop

      public List<com.hybris.cockpitng.dnd.DropOperationData<DRAGGED,TARGET,Object>> handleDrop(List<DRAGGED> dragged, TARGET target, com.hybris.cockpitng.dnd.DragAndDropContext context)
      Specified by:
      handleDrop in interface com.hybris.cockpitng.dnd.DropHandler<DRAGGED,TARGET>
    • resolveActionType

      protected com.hybris.cockpitng.dnd.DragAndDropActionType resolveActionType(com.hybris.cockpitng.dnd.DragAndDropContext context)
    • handleAppend

      protected abstract List<com.hybris.cockpitng.dnd.DropOperationData<DRAGGED,TARGET,Object>> handleAppend(List<DRAGGED> dragged, TARGET target, com.hybris.cockpitng.dnd.DragAndDropContext context)
      Returns the result of appending of the dragged object to the target.
      Parameters:
      dragged - dragged objects.
      target - target object on which dragged objects are dropped.
      context - context of drag&drop operation.
    • handleReplace

      protected abstract List<com.hybris.cockpitng.dnd.DropOperationData<DRAGGED,TARGET,Object>> handleReplace(List<DRAGGED> dragged, TARGET target, com.hybris.cockpitng.dnd.DragAndDropContext context)
      Returns the result of replacing of the dragged object in the target.
      Parameters:
      dragged - dragged objects.
      target - target object on which dragged objects are dropped.
      context - context of drag&drop operation.
    • getDragAndDropConfigurationService

      protected com.hybris.cockpitng.services.dnd.DragAndDropConfigurationService getDragAndDropConfigurationService()
    • setDragAndDropConfigurationService

      public void setDragAndDropConfigurationService(com.hybris.cockpitng.services.dnd.DragAndDropConfigurationService dragAndDropConfigurationService)