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

pl.touk.nussknacker.ui.db.DBIOActionExtensions.scala Maven / Gradle / Ivy

There is a newer version: 1.17.0
Show newest version
package pl.touk.nussknacker.ui.db

import db.util.DBIOActionInstances.DB
import pl.touk.nussknacker.ui.process.repository.DBIOActionRunner

import scala.concurrent.Future

trait DBIOActionExtensions {

  implicit class RunExtension[T](action: DB[T]) {
    def run(implicit runner: DBIOActionRunner): Future[T] =
      runner.run(action)

    def runInTransaction(implicit runner: DBIOActionRunner): Future[T] =
      runner.runInTransaction(action)
  }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy