KeyedCrudBase

usql.dao.KeyedCrudBase
abstract class KeyedCrudBase[K, T](using keyDataType: DataType[K]) extends CrdBase[T], KeyedCrud[T]

Implementation of KeyedCrd for KeyedTabular data.

Attributes

Graph
Supertypes
trait KeyedCrud[T]
class CrdBase[T]
trait Crd[T]
class Object
trait Matchable
class Any
Show all

Members list

Type members

Types

override type Key = K

Type of the key

Type of the key

Attributes

Value members

Abstract methods

override def keyOf(value: T): K

Returns the key of a value.

Returns the key of a value.

Attributes

Definition Classes

Concrete methods

override def deleteByKey(key: K)(using ConnectionProvider): Int

Delete by key.

Delete by key.

Attributes

Definition Classes
override def findByKey(key: K)(using ConnectionProvider): Option[T]

Find one by key.

Find one by key.

Attributes

Definition Classes
override def update(value: T)(using ConnectionProvider): Int

Update some value.

Update some value.

Attributes

Definition Classes

Inherited methods

override def countAll()(using ConnectionProvider): Int

Count all instances.

Count all instances.

Attributes

Definition Classes
Inherited from:
CrdBase
override def deleteAll()(using ConnectionProvider): Int

Delete all instances.

Delete all instances.

Attributes

Definition Classes
Inherited from:
CrdBase
def findAgain(value: T)(using ConnectionProvider): Option[T]

Load some value again based upon key.

Load some value again based upon key.

Attributes

Inherited from:
KeyedCrud
override def findAll()(using ConnectionProvider): Seq[T]

Find all instances

Find all instances

Attributes

Definition Classes
Inherited from:
CrdBase
override def insert(values: Seq[T])(using ConnectionProvider): Int

Insert many elements.

Insert many elements.

Attributes

Definition Classes
Inherited from:
CrdBase
def insert(value1: T, value2: T, values: T*)(using ConnectionProvider): Int

Insert many elements

Insert many elements

Attributes

Inherited from:
Crd
def insert(value: T)(using ConnectionProvider): Int

Insert into database.

Insert into database.

Attributes

Inherited from:
Crd

Abstract fields

The column of the key

The column of the key

Attributes

Inherited fields

lazy protected val selectAll: Sql

Select All Statement, may be reused.

Select All Statement, may be reused.

Attributes

Inherited from:
CrdBase
lazy val tabular: SqlTabular[T]

Attributes

Inherited from:
CrdBase

Givens

Inherited givens

protected given pf: ParameterFiller[T]

Attributes

Inherited from:
CrdBase
protected given rd: ResultRowDecoder[T]

Attributes

Inherited from:
CrdBase