Class SimpleProgressAdapter

java.lang.Object
ca.corbett.extras.progress.SimpleProgressAdapter
All Implemented Interfaces:
SimpleProgressListener

public class SimpleProgressAdapter extends Object implements SimpleProgressListener
Simple adapter class for SimpleProgressListener. None of these methods do anything.
Since:
2022-05-10
Author:
scorbo2
  • Constructor Details

    • SimpleProgressAdapter

      public SimpleProgressAdapter()
  • Method Details

    • progressBegins

      public void progressBegins(int totalStepCount)
      Invoked by the worker when an operation has begun or is about to begin.
      Specified by:
      progressBegins in interface SimpleProgressListener
      Parameters:
      totalStepCount - The total steps that will occur during this operation.
    • progressUpdate

      public boolean progressUpdate(int currentStep, String message)
      Invoked by the worker at the completion of each step of this operation. You can cancel the rest of the operation by returning false here.
      Specified by:
      progressUpdate in interface SimpleProgressListener
      Parameters:
      currentStep - The numeric index of the current step in this operation.
      message - An informational message about the current step.
      Returns:
      Return true to continue processing, or false if you wish to cancel the operation.
    • progressError

      public boolean progressError(String errorSource, String errorDetails)
      Invoked by the worker if a recoverable error occurs during the scan operation. The operation will continue.
      Specified by:
      progressError in interface SimpleProgressListener
      Parameters:
      errorSource - A message describing what caused the error.
      errorDetails - Additional details about the error.
      Returns:
      Return true to continue processing, or false if you wish to cancel the operation.
    • progressComplete

      public void progressComplete()
      Invoked by the worker when the operation completes. No further messages will be invoked unless a new operation is requested.
      Specified by:
      progressComplete in interface SimpleProgressListener
    • progressCanceled

      public void progressCanceled()
      Invoked by the worker if the operation is canceled before completion. No further messages will be invoked unless a new operation is requested.
      Specified by:
      progressCanceled in interface SimpleProgressListener