Class ProgressMonitorDecorator

    • Constructor Detail

      • ProgressMonitorDecorator

        public ProgressMonitorDecorator​(ProgressMonitor delegate)
    • Method Detail

      • start

        public void start​(@NotNull
                          String taskName,
                          int totalWork)
        Description copied from interface: ProgressMonitor
        Starts monitoring, can only be called once.
        Specified by:
        start in interface ProgressMonitor
        Parameters:
        taskName - The text to display in the progress dialog header, must not be null, can be an empty string, e.g. to keep the amount of text in the progress dialog low
        totalWork - The amount of work items to finish before completion, can be 0, in which case no advances are possible
      • advance

        public void advance​(int work)
        Description copied from interface: ProgressMonitor
        Advance by the given number of work items.
        Specified by:
        advance in interface ProgressMonitor
        Parameters:
        work - The number of work items accomplished, 0 is allowed and can be used as a way to complete an unfinished sub-task's monitor
      • step

        public void step​(String title)
        Description copied from interface: ProgressMonitor
        Indicates a new step to mention in the progress dialog
        Specified by:
        step in interface ProgressMonitor
        Parameters:
        title - The text to show in the progress dialog
      • subTask

        public ProgressMonitor subTask​(int work)
        Description copied from interface: ProgressMonitor
        Creates a monitor for a sub-task, which, when accomplished, will complete the given number of work items of the current monitor. At most one sub-task can be active for a given task at any moment.
        Specified by:
        subTask in interface ProgressMonitor
        Parameters:
        work - The number of work items to advance the current monitor when the sub-task completes
        Returns:
        The progress monitor for the sub-task.
      • subTask

        public ProgressMonitor subTask​(int work,
                                       SubProgressKind kind)
        Description copied from interface: ProgressMonitor
        Creates a monitor for a sub-task, which, when accomplished, will complete the given number of work items of the current monitor. At most one sub-task can be active for a given task at any moment.
        Specified by:
        subTask in interface ProgressMonitor
        Parameters:
        work - The number of work items to advance the current monitor when the sub-task completes
        kind - Specifies whether and how textual information from the sub-task's monitor will be propagated onto the progress dialog
        Returns:
        The progress monitor for the sub-task.