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

spice.util.WorkResult.scala Maven / Gradle / Ivy

There is a newer version: 0.7.2
Show newest version
package spice.util

import cats.effect.IO

sealed trait WorkResult[Result]

object WorkResult {
  /**
   * The final result. The work if finished.
   */
  case class FinalResult[Result](result: Result) extends WorkResult[Result]

  /**
   * The intermediate result. The work is partially completed, but more work needs to be done before it's fully complete.
   * The `complete` will be asynchronously executed to finish the partially completed work.
   */
  case class ProgressiveResult[Result](result: Result, complete: IO[Result]) extends WorkResult[Result]
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy