Interface SyncProgressListener

All Superinterfaces:
ProgressListener

public interface SyncProgressListener extends ProgressListener
Receives progress notifications from folder synchronization and deletion jobs, and lets the caller cancel them. Progress is reported both as bytes and as items transferred, because neither alone is accurate in every case: copying a single large file, for instance, versus copying thousands of empty files.
Since:
2.0
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    bytesTransferred(long byteCount)
    Notifies that byteCount bytes have been transferred, and lets the listener stop the operation by returning false.
    void
    Notifies that the transfer of an item has failed.
    void
    Notifies that the transfer of an item has completed.

    Methods inherited from interface com.deltawalker.script.ProgressListener

    done, isCanceled, subTask, worked
  • Method Details

    • bytesTransferred

      boolean bytesTransferred(long byteCount)
      Notifies that byteCount bytes have been transferred, and lets the listener stop the operation by returning false.
      Parameters:
      byteCount - the number of bytes that have been copied or moved
      Returns:
      true to continue with the operation, false to stop
      Since:
      2.0
    • itemFailed

      void itemFailed(Throwable ex)
      Notifies that the transfer of an item has failed. In the current release this method is not called.
      Parameters:
      ex - the Throwable describing the failure
      Since:
      2.0
    • itemTransferred

      void itemTransferred()
      Notifies that the transfer of an item has completed.
      Since:
      2.0