Interface FoldableAction

  • All Superinterfaces:
    Action, ModelObject
    All Known Implementing Classes:
    CauseAction

    public interface FoldableAction
    extends Action
    An action interface that allows action data to be folded together.

    Action can implement this optional marker interface to be notified when the Queue.Task that it's added to the queue with is determined to be "already in the queue".

    This is useful for passing on parameters to the task that's already in the queue.

    Since:
    1.300-ish.
    Author:
    mdonohue
    • Method Detail

      • foldIntoExisting

        void foldIntoExisting​(Queue.Item item,
                              Queue.Task owner,
                              List<Action> otherActions)
        Notifies that the Queue.Task that "owns" this action (that is, the task for which this action is submitted) is considered as a duplicate.
        Parameters:
        item - The existing Queue.Item in the queue against which we are judged as a duplicate. Never null.
        owner - The Queue.Task with which this action was submitted to the queue. Never null.
        otherActions - Other Actions that are submitted with the task. (One of them is this FoldableAction.) Never null.