类 MonitorableProgressListener

java.lang.Object
cn.warpin.thirdPart.huawei.obs.obs.services.model.MonitorableProgressListener
所有已实现的接口:
ProgressListener

public abstract class MonitorableProgressListener extends Object implements ProgressListener
Implementation class of the data transmission listener that can monitor the running status of subprocesses
从以下版本开始:
3.20.3
  • 字段概要

    字段
    修饰符和类型
    字段
    说明
    private static final ILogger
     
     
  • 构造器概要

    构造器
    构造器
    说明
     
  • 方法概要

    修饰符和类型
    方法
    说明
    final void
    End a subtask.

    Note: Generally, users are not advised to call this method, because calling this method may lead to failures of the waitingFinish and isRunning methods.
    final boolean
    Check whether the request task is running.
    final void
    Reset the listener.

    This method is used when a request is repeatedly used.
    final void
    Start a subtask.

    Note: Generally, users are not advised to call this method, because calling this method may lead to failures of the waitingFinish and isRunning methods.
    final boolean
    Wait until the request task is completely executed.
    final boolean
    waitingFinish(long timeout)
    Wait until the request task is completely executed.

    从类继承的方法 java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    从接口继承的方法 cn.warpin.thirdPart.huawei.obs.obs.services.model.ProgressListener

    progressChanged
  • 字段详细资料

  • 构造器详细资料

    • MonitorableProgressListener

      public MonitorableProgressListener()
  • 方法详细资料

    • isRunning

      public final boolean isRunning()
      Check whether the request task is running.
      This method is used by the parent thread to monitor whether the current thread has completely stopped running after the current thread executes the interrupt() method.
      返回:
      If there are still running subtasks, true is returned. Otherwise, false is returned.
      从以下版本开始:
      3.20.3
    • waitingFinish

      public final boolean waitingFinish() throws InterruptedException
      Wait until the request task is completely executed. Before the task execution completes, this method is blocked.

      This method is used to check whether the upload subtask is complete after the current thread executes the interrupt() method.
      返回:
      If the task is complete, true is returned. Otherwise, false is returned.
      抛出:
      InterruptedException - This exception is thrown when the thread is in waiting, sleep, or occupied state before or during the activity and the thread is interrupted.
      从以下版本开始:
      3.20.3
    • waitingFinish

      public final boolean waitingFinish(long timeout) throws InterruptedException
      Wait until the request task is completely executed. Before the task is completely executed, the method is blocked until the timeout interval is exceeded.

      This method is used to check whether the upload subtask is complete after the current thread executes the interrupt() method.
      参数:
      timeout - Timeout interval, in milliseconds. If the parameter value is smaller than or equal to 0, the waiting never times out.
      返回:
      If the task is complete, true is returned. Otherwise, false is returned.
      抛出:
      InterruptedException - This exception is thrown when the thread is in waiting, sleep, or occupied state before or during the activity and the thread is interrupted.
      从以下版本开始:
      3.20.3
    • startOneTask

      public final void startOneTask()
      Start a subtask.

      Note: Generally, users are not advised to call this method, because calling this method may lead to failures of the waitingFinish and isRunning methods. The SDK uses this method to adjust the number of running subtasks. The user determines whether the requested task is complete.

      Reference: waitingFinish(long), isRunning()
      从以下版本开始:
      3.20.3
    • finishOneTask

      public final void finishOneTask()
      End a subtask.

      Note: Generally, users are not advised to call this method, because calling this method may lead to failures of the waitingFinish and isRunning methods. The SDK uses this method to adjust the number of running subtasks. The user determines whether the requested task is complete.

      Reference: waitingFinish(long), isRunning()
      从以下版本开始:
      3.20.3
    • reset

      public final void reset()
      Reset the listener.

      This method is used when a request is repeatedly used.
      从以下版本开始:
      3.20.3