Interface ParentItemObject<T extends ControlflowItemObject>

All Superinterfaces:
AbstractWorkflowItemObject, ControlflowItemObject, DataObject, PropertyHandler, StatusableObject
All Known Subinterfaces:
NodeObject, SequenceObject, SubWorkflowObject
All Known Implementing Classes:
NodeObjectImpl, ParentItemObjectImpl, SequenceObjectImpl

public interface ParentItemObject<T extends ControlflowItemObject> extends ControlflowItemObject
Interface of an abstract object used in the controlflow of a workflow. CAKE III - Extension. Represents a workflowobject, which can be integrated in a sequence. Current descendants are WorkflowNode and WorkflowLeaf.
Author:
Alexander Stromer
  • Method Details

    • getNextSibling

      T getNextSibling(String fromId)
      Returns the next (insertion-order) item lodated below the same parent.
      Parameters:
      fromId - Id of the current item.
      Returns:
      Next item. NULL, if it doesn't exist.
    • getPreviousSibling

      T getPreviousSibling(String fromId)
      Returns the previous (insertion-order) item located below the same parent.
      Parameters:
      fromId - Id of the current item.
      Returns:
      Previous item. NULL, if it doesn't exist.
    • insertAfter

      void insertAfter(String fromId, T newObject)
      Inserts the given object after the item with the given id.
      Parameters:
      fromId - Id of the object to insert the object after.
      newObject - The object, which has to be inserted.
    • insertBefore

      void insertBefore(String fromId, T newObject)
      Inserts the given object before the item with the given id.
      Parameters:
      fromId - Id of the object to insert the object before.
      newObject - The object, which has to be inserted.
    • deepSearchItem

      ControlflowItemObject deepSearchItem(String id)
      Searches the item with the given Id in the tree below the current object and returns it.
      Parameters:
      id - The Id of the object which has to be searched.
      Returns:
      The object, if the object with the given Id was found; NULL otherwise.
    • getItem

      T getItem(String id)
      Returns the item with the given Id if it is directly connected to this object.
      Parameters:
      id - The Id of the object, which has to be found.
      Returns:
      The object, if the object with the given Id was found; NULL otherwise.
    • addItem

      boolean addItem(T newObject)
      Adds the given object to the list of items.
      Parameters:
      newObject - The object, which has to be added.
      Returns:
      TRUE, if the add-operation was successful; FALSE otherwise.
    • getItems

      LinkedList<T> getItems()
      Returns the list of items, sorted according to the operations done on the list.
      Returns:
      Ordered list of items.
    • removeItem

      boolean removeItem(String id)
      Removes the item with the given id of the list.
      Parameters:
      id - Id of the item to remove.
      Returns:
      TRUE, if an object with the given Id was removed. FALSE otherwise.
    • getFirstItem

      T getFirstItem()
      Returns the first item of the list.
      Returns:
      First item of the list; NULL, if there is no item in the list.