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

org.atnos.eff.syntax.batch.scala Maven / Gradle / Ivy

The newest version!
package org.atnos.eff.syntax

import org.atnos.eff._

object batch extends batch

trait batch {
  implicit final def toBatchOps[R, A](e: Eff[R, A]): BatchOps[R, A] = new BatchOps(e)
}

final class BatchOps[R, A](private val e: Eff[R, A]) extends AnyVal {

  def batch[T[_]](implicit batchable: Batchable[T], member: T /= R): Eff[R, A] =
    Batch.batch[R, T, A](e)(batchable, member)

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy