aboutsummaryrefslogtreecommitdiff
path: root/src/main/scala/xyz/driver/pdsuicommon/db/DbIo.scala
blob: 7c290d10fb223c6445a913a075f2cec628d21a5e (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
package xyz.driver.pdsuicommon.db

import scala.concurrent.Future

/**
  * Where queries should run
  */
trait DbIo {
  def runAsync[T](f: => T): Future[T]
  def runSync[T](f: => T): T = f
  def runAsyncTx[T](f: => T): Future[T]
  def runSyncTx[T](f: => T): Unit
}