scalikejdbc

NamedDB

case class NamedDB(name: Any)(implicit context: ConnectionPoolContext = NoConnectionPoolContext) extends Product with Serializable

Named Basic DB Accessor

It's easier to use named ConnectionPool with this class.

ConnectionPool.add('named, "jdbc:...", "user", "password")
val users = NamedDB('named) readOnly { session =>
  session.list("select * from user")
}
Linear Supertypes
Serializable, Serializable, Product, Equals, AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. NamedDB
  2. Serializable
  3. Serializable
  4. Product
  5. Equals
  6. AnyRef
  7. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new NamedDB(name: Any)(implicit context: ConnectionPoolContext = NoConnectionPoolContext)

Value Members

  1. final def !=(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

    Definition Classes
    AnyRef → Any
  4. final def ==(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  5. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  6. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  7. def autoCommit[A](execution: (DBSession) ⇒ A): A

  8. def autoCommitSession(): DBSession

  9. def autoCommitWithConnection[A](execution: (Connection) ⇒ A): A

  10. def begin(): Unit

  11. def beginIfNotYet(): Unit

  12. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  13. def close(): Unit

  14. def commit(): Unit

  15. def currentTx: Tx

  16. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  17. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  18. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  19. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  20. def isTxAlreadyStarted: Boolean

  21. def isTxNotActive: Boolean

  22. def isTxNotYetStarted: Boolean

  23. def localTx[A](execution: (DBSession) ⇒ A): A

  24. def localTxWithConnection[A](execution: (Connection) ⇒ A): A

  25. val name: Any

  26. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  27. def newTx: Tx

  28. final def notify(): Unit

    Definition Classes
    AnyRef
  29. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  30. def readOnly[A](execution: (DBSession) ⇒ A): A

  31. def readOnlySession(): DBSession

  32. def readOnlyWithConnection[A](execution: (Connection) ⇒ A): A

  33. def rollback(): Unit

  34. def rollbackIfActive(): Unit

  35. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  36. def tx: Tx

  37. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws()
  38. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws()
  39. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws()
  40. def withinTx[A](execution: (DBSession) ⇒ A): A

  41. def withinTxSession(tx: Tx = currentTx): DBSession

  42. def withinTxWithConnection[A](execution: (Connection) ⇒ A): A

Inherited from Serializable

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from AnyRef

Inherited from Any

No Group