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

eventstore.util.CancellableAdapter.scala Maven / Gradle / Ivy

The newest version!
package eventstore.util

import akka.actor.Cancellable

object CancellableAdapter {
  def apply(cancellables: Cancellable*): Cancellable = new Cancellable {
    require(cancellables.nonEmpty, "cancellables are empty")

    def cancel() = cancellables.map(_.cancel()).min

    def isCancelled = cancellables.forall(_.isCancelled)
  }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy