All Downloads are FREE. Search and download functionalities are using the official Maven repository.

commonMain.report.NoOpProgressReporter.kt Maven / Gradle / Ivy

package opensavvy.progress.report

import opensavvy.progress.Progress

// Private object because otherwise IDEA wants to statically import NoOpProgressReporter.report everywhere, which
// is a foot-gun.
private object NoOpProgressReporter : ProgressReporter {
    override fun report(progress: Progress) {}

    override fun toString() = "NoOpProgressReporter"
}

/**
 * A [ProgressReporter] implementation that does nothing.
 */
fun emptyProgressReporter(): ProgressReporter = NoOpProgressReporter




© 2015 - 2024 Weber Informatics LLC | Privacy Policy