Interface StatusManager

All Known Implementing Classes:
DefaultStatusManager

@PublicApi public interface StatusManager
Manager for Statuses.
Since:
v5.0
  • Method Details

    • createStatus

      Status createStatus(String name, String description, String iconUrl, StatusCategory statusCategory)
      Creates a new status.
      Parameters:
      name - name of the status. Cannot be blank or null and has to be unique.
      description - description of the status.
      iconUrl - icon url for this status. Cannot be blank or null.
      statusCategory - status category of the status. Cannot be null
      Returns:
      the new Status.
      Since:
      6.1
    • createStatus

      Status createStatus(String name, String description, String iconUrl)
      Creates a new status.
      Parameters:
      name - name of the status. Cannot be blank or null and has to be unique.
      description - description of the status.
      iconUrl - icon url for this status. Cannot be blank or null.
      Returns:
      the new Status.
    • editStatus

      void editStatus(Status status, String name, String description, String iconUrl, StatusCategory statusCategory)
      Edit an existing status.
      Parameters:
      status - status to edit.
      name - new name. Has to be unique.
      description - new description
      iconUrl - new icon url
      statusCategory - status category of the status. Cannot be null
      Since:
      6.1
    • editStatus

      void editStatus(Status status, String name, String description, String iconUrl)
      Edit an existing status.
      Parameters:
      status - status to edit.
      name - new name. Has to be unique.
      description - new description
      iconUrl - new icon url
    • getStatuses

      Collection<Status> getStatuses()
      Returns:
      all Statuses
    • removeStatus

      void removeStatus(String id)
      Removes a status.
      Parameters:
      id - status id
      Throws:
      IllegalStateException - if this status is associated with any workflow.
      IllegalArgumentException - if a status with the given id does not exist.
    • getStatus

      Status getStatus(String id)
      Get a status by id.
      Parameters:
      id - status id
      Returns:
      the Status, or null if no status with this id exists.
    • moveStatusUp

      void moveStatusUp(String id)
      Move the status up in the order.
      Parameters:
      id - id of the status.
      Throws:
      IllegalArgumentException - if a status with the given id does not exist.
    • moveStatusDown

      void moveStatusDown(String id)
      Move the status down in the order.
      Parameters:
      id - id of the status.
      Throws:
      IllegalArgumentException - if a status with the given id does not exist.