OneMergeProgress

Progress and state for an executing merge. This class encapsulates the logic to pause and resume the merge thread or to abort the merge entirely.

Constructors

Link copied to clipboard
constructor()

Types

Link copied to clipboard

Reason for pausing the merge thread.

Properties

Link copied to clipboard

Return the aborted state of this merge.

Functions

Link copied to clipboard
suspend fun abort()

Abort the merge this progress tracks at the next possible moment.

Link copied to clipboard
suspend fun pauseNanos(initialPauseNanos: Long, reason: MergePolicy.OneMergeProgress.PauseReason, condition: () -> Boolean)

Pauses the calling thread for at least pauseNanos nanoseconds unless the merge is aborted or the external condition returns false, in which case control returns immediately.

Link copied to clipboard
fun setMergeThread(owner: Job)
Link copied to clipboard
suspend fun wakeup()

Request a wakeup for any threads stalled in .pauseNanos.