Class JobPlanTask

java.lang.Object
com.uc4.api.objects.JobPlanTask
All Implemented Interfaces:
ITaskItem

public class JobPlanTask extends Object implements ITaskItem
Task in the JobPlan.
  • Constructor Details

    • JobPlanTask

      public JobPlanTask(com.uc4.util.XMLDocument doc, Element task, ConnectionAttributes session)
      Constructs a JobPlanTask from the specified XML document. Internal use only.
      Parameters:
      doc - XML document
      task - Task element
      session - Session info
  • Method Details

    • store

      public Element store(com.uc4.util.XMLDocument doc, Element jobpStruct)
      Parameters:
      doc - XMLDocument
      jobpStruct - Jobplan structure
      Returns:
      Element
    • getIdnr

      public String getIdnr()
      Description copied from interface: ITaskItem
      Returns the ID of this or ScheduleTask task.
      Specified by:
      getIdnr in interface ITaskItem
      Returns:
      String containing the ID
    • setIdnr

      protected void setIdnr(String idnr)
    • checkpoint

      @Deprecated public JobPlanCheckpoint checkpoint()
      Deprecated.
      use the method general() instead
      Gets the checkpoint settings of this JobPlan task. If this method is called on the START task an IllegalStateException is thrown.
      Returns:
      Checkpoint settings
    • getUserDefinedID

      public String getUserDefinedID()
      Returns the user defined ID of this task or null if not set.
      Returns:
      User defined task ID
    • setUserDefinedID

      public void setUserDefinedID(String userDefinedID)
      Sets the user defined task ID. This value can later be used to identify this task using the JobPlan.getTaskByUserID() method
      Parameters:
      userDefinedID - Any String with should be used to identify the task later
    • general

      public ProcessFlowGeneral general()
      This methdo provides access to the "General" tab of a ProcessFlow task. If this method is called on the START task an IllegalStateException is thrown.
      Returns:
      General settings
    • values

      public TaskValues values()
      Description copied from interface: ITaskItem
      Provides access to the values and PromptSets of a Schedule or Workflow task.
      Specified by:
      values in interface ITaskItem
      Returns:
      Values and PromptSets
    • raPanel

      public OCVPanel raPanel()
      If this task is an RA solution and the Workflow has been saved and reopened this method can be used to override RA panel values.
      Returns:
      Read and Write access to the XML names of the RA panel.
    • preConditions

      public ConditionsSet preConditions()
      This method provides access to the "Pre-Conditions" of a JobPlan task.
      Returns:
      ConditionSet which contains all Pre-Conditions
    • postConditions

      public ConditionsSet postConditions()
      This method provides access to the "Post-Conditions" of a JobPlan task.
      Returns:
      ConditionSet which contains all Post-Conditions
    • earliest

      public JobPlanEarliest earliest()
      Gets the earliest start time settings of this JobPlan task.
      Returns:
      Earliest start time settings
    • hasCalendarCondition

      public boolean hasCalendarCondition()
      Specified by:
      hasCalendarCondition in interface ITaskItem
      Returns:
      true if this task has a calendar condition.
    • hasRuntimeCondition

      public boolean hasRuntimeCondition()
      Specified by:
      hasRuntimeCondition in interface ITaskItem
      Returns:
      true if this task has a runtime condition.
    • calendar

      public TaskCalendar calendar()
      Gets the calendar condition of this JobPlan task. If this method is called on the START or END task an IllegalStateException is thrown.
      Specified by:
      calendar in interface ITaskItem
      Returns:
      Calendar conditions
    • runtime

      public TaskRuntime runtime()
      Gets the runtime settings of this JobPlan task. If this method is called on the START or END task an IllegalStateException is thrown.
      Specified by:
      runtime in interface ITaskItem
      Returns:
      Runtime settings
    • dependencies

      public JobPlanDependencies dependencies()
      Gets the dependencies of this JobPlan task.
      Returns:
      Dependencies
    • getTaskName

      public String getTaskName()
      Gets the name of this JobPlan task.
      Specified by:
      getTaskName in interface ITaskItem
      Returns:
      Name of the task
    • getType

      public String getType()
      Description copied from interface: ITaskItem
      Returns the object type of this task.
      Specified by:
      getType in interface ITaskItem
      Returns:
      Object type
    • getSubType

      public String getSubType()
      Gets the object Subtype of this task.
      Returns:
      Object Subtype
    • getRASubJobType

      public String getRASubJobType()
      Gets the object Subtype of this RA task.
      Returns:
      Object RaSubtype
    • getRAJobType

      public String getRAJobType()
      Returns the Job type of this RA task.
      Returns:
      Object RaJobtype
    • getRaAgentName

      public String getRaAgentName()
      Returns:
      the raAgentName
    • getX

      public int getX()
      Returns the column number of this JobPlan task. The first column starts with 1.
      Returns:
      Column number
    • getY

      public int getY()
      Returns the row number of this JobPlan task. The first row starts with 1.
      Returns:
      Row number
    • getLnr

      public int getLnr()
      Description copied from interface: ITaskItem
      Returns number containing the order of activation. A task with Lnr = 1 is executed first.
      Specified by:
      getLnr in interface ITaskItem
      Returns:
      Order of activation
    • setLnr

      protected void setLnr(int lnr)
    • setX

      public void setX(int x)
      Sets the column number of this task. The first column starts with 1. When the JobPlan is saved the position of all tasks is checked.
      Parameters:
      x - Column number
    • setY

      public void setY(int y)
      Sets the row number of this task. The first row starts with 1. When the JobPlan is saved the position of all tasks is checked.
      Parameters:
      y - Row number
    • setTaskName

      protected void setTaskName(String taskName)
    • setType

      protected void setType(String type)
    • setExternal

      public void setExternal()
      Do not use - only for testing! Sets this task to type EXTERNAL
    • external

      public JobPlanExternal external()
      Gets properties for external dependencies. If this method is called and the JobPlan task is not an external dependency an IllegalStateException is thrown.
      Returns:
      Settings for external dependency
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • isAdded

      protected boolean isAdded()
    • setAdded

      protected void setAdded(boolean added)
    • isExternal

      public boolean isExternal()
      Returns true if this task is an external dependency.
      Returns:
      True if this task is an external dependency
    • getHostName

      public UC4HostName getHostName()
      Returns the hostName for the JobPlan task if exist otherwise will return null
      Returns:
      UC4HostName if exist for the JobPlanTask
    • getTitleOrName

      public String getTitleOrName()
      Return the Task Title if available else the name of the task object
      Returns:
      A string representing the title or name
    • getTaskIcon

      public String getTaskIcon()
      Return the Task Icon
      Returns:
      String representing the taskIcon
    • getTaskTitle

      public String getTaskTitle()
      Return the Title of the Task
      Returns:
      String representing the job Title
    • isInactive

      public boolean isInactive()
      Return the status of the task
      Returns:
      boolean representing the status
    • copy

      public JobPlanTask copy()
      Creates a copy of this task with only the properties set.
      Returns:
      A new task with the properties duplicated from this task.
    • copyWithTaskValues

      public JobPlanTask copyWithTaskValues()
      Creates a copy of this task, inclusive of TaskValues (Variables and PromptSets).
      Returns:
      A new task with the properties duplicated from this task.
    • cloneProperties

      public void cloneProperties(JobPlanTask toClone)
      Creates a deep copy of all task properties of the given task for this task, except the task values (prompts and variables).
      Parameters:
      toClone - The task whose properties to clone.
    • clonePropertiesAndTaskValues

      public void clonePropertiesAndTaskValues(JobPlanTask toClone)
      Creates a deep copy of all task properties of the given task for this task, including the task values (prompts and variables).
      Parameters:
      toClone - The task whose properties and task values to clone.