Package

co.actioniq.luna

dao

Permalink

package dao

Visibility
  1. Public
  2. All

Type Members

  1. trait DAO[T <: Table[V, I, P], V <: IdModel[I], I <: IdType, P <: JdbcProfile] extends DAOAction[T, V, I, P]

    Permalink

    Top of the DAO traits, this actually runs the actions in a transaction.

    Top of the DAO traits, this actually runs the actions in a transaction. Most functions return a scala future

    T

    slick table, extends aiqtable

    V

    case class to store result set rows

    I

    id type (option long and uuid)

  2. trait DAOAction[T <: Table[V, I, P], V <: IdModel[I], I <: IdType, P <: JdbcProfile] extends DAOQuery[T, V, I, P] with DAOHook[V] with DAOActionValidate[V]

    Permalink

    Take the queries generated and actually perform the action.

    Take the queries generated and actually perform the action. Most functions return a nonblocking DBIOAction

    T

    slick table, extends aiqtable

    V

    case class to store result set rows

    I

    id type (option long and uuid)

  3. trait DAOActionValidate[V] extends AnyRef

    Permalink

    Trait with functions to implement to perform validations.

    Trait with functions to implement to perform validations. Functions need to return DBIOActions so that they can be included in transactions. You would probably do DBIO.successful(....)

    V

    model / slick case class

  4. class DAODynamicProfileTable[P <: JdbcProfile] extends AnyRef

    Permalink
  5. class DAOException extends Exception

    Permalink
  6. trait DAOFormValidator[V] extends AnyRef

    Permalink

    Simple form validator, we should probably spend more time on this and make it better.

    Simple form validator, we should probably spend more time on this and make it better. Idea is that we can validate create or update, run db queries, and handle multiple validation errors

    V

    case class recordset

  7. trait DAOH2Profile extends H2Profile

    Permalink
  8. trait DAOHook[V] extends AnyRef

    Permalink

    Trait that adds the ability to create functional hooks at different stages in write operations (for altering data or failing)

    Trait that adds the ability to create functional hooks at different stages in write operations (for altering data or failing)

    V

    case class for recordsets

  9. trait DAOLongIdQuery[T <: Table[V, DbLongOptId, P], V <: IdModel[DbLongOptId], P <: JdbcProfile] extends IdQuery[T, V, DbLongOptId, P] with JdbcTypes[P] with InSeqDbUUIDImplicits

    Permalink

    Implementation of handling queries with option[long] id

    Implementation of handling queries with option[long] id

    T

    slick table, extends aiqtable

    V

    case class to store result set rows

  10. trait DAOMySQLProfile extends MySQLProfile

    Permalink
  11. trait DAOQuery[T <: Table[V, I, P], V <: IdModel[I], I <: IdType, P <: JdbcProfile] extends DefaultFilter[T, V, I, P] with IdQuery[T, V, I, P]

    Permalink

    Generates the base queries that most DAO classes will need

    Generates the base queries that most DAO classes will need

    T

    slick table, extends aiqtable

    V

    case class to store result set rows

    I

    id type (option long and uuid)

  12. trait DAOUUIDQuery[T <: Table[V, DbUUID, P], V <: IdModel[DbUUID], P <: JdbcProfile] extends IdQuery[T, V, DbUUID, P] with JdbcTypes[P] with InSeqDbUUIDImplicits

    Permalink

    Implementation of handling queries with UUID

    Implementation of handling queries with UUID

    T

    slick table, extends aiqtable

    V

    case class to store result set rows

  13. case class DbLongOptId(value: Option[Long]) extends IdType with Product with Serializable

    Permalink

    IdType that represents an id of Option[Long]

    IdType that represents an id of Option[Long]

    value

    underlying value (Option[Long])

  14. case class DbUUID(binValue: Array[Byte]) extends IdType with Product with Serializable

    Permalink

    IdType that represents a UUID stored as an array[byte] / binary

    IdType that represents a UUID stored as an array[byte] / binary

    binValue

    array[byte] representing the UUID

  15. trait DefaultFilter[T <: Table[V, I, P], V <: IdModel[I], I <: IdType, P <: JdbcProfile] extends AnyRef

    Permalink

    Default filter is the "lowest" level of the dao traits that simply lets you add a default filter to any query that the DAO runs.

    Default filter is the "lowest" level of the dao traits that simply lets you add a default filter to any query that the DAO runs. This is useful for customer_id, team_id, etc...

    T

    slick table, extends aiqtable

    V

    case class to store result set rows

    I

    id type (option long and uuid)

  16. class FormValidatorExceptions extends Exception

    Permalink

    Exception class that wraps multiple validation errors

  17. case class FormValidatorMessage(message: String, code: Option[String] = None) extends Product with Serializable

    Permalink

    Class wrapping validation error messages

    Class wrapping validation error messages

    message

    error message to return to user

    code

    optional code for easier parsing

  18. case class FormValidatorMessageSeq(errors: Seq[FormValidatorMessage] = Nil) extends Product with Serializable

    Permalink

    Wrapper class around a seq of form validation messages / failures.

    Wrapper class around a seq of form validation messages / failures. Empty means form validated correctly

    errors

    seq of form validator messages

  19. trait H2DAO[T <: H2DAOTable[V, I], V <: IdModel[I], I <: IdType] extends DAO[T, V, I, DAOH2Profile] with DbImplicits

    Permalink
  20. abstract class H2DAOTable[V <: IdModel[I], I <: IdType] extends dao.DAOH2Profile.Table[V] with IdTable[I] with DbImplicits

    Permalink
  21. trait H2IdModel[I <: IdType] extends IdModel[I] with DbImplicits

    Permalink
  22. trait IdModel[I <: IdType] extends AnyRef

    Permalink

    Any DAO model that has an id

    Any DAO model that has an id

    I

    IdType

  23. trait IdQuery[T <: Table[V, I, P], V <: IdModel[I], I <: IdType, P <: JdbcProfile] extends DefaultFilter[T, V, I, P]

    Permalink

    Functions for handling queries against the different id types

    Functions for handling queries against the different id types

    T

    slick table, extends aiqtable

    V

    case class to store result set rows

    I

    id type (option long and uuid)

  24. trait IdTable[I <: IdType] extends AnyRef

    Permalink

    A table that has an IDType for an ID

    A table that has an IDType for an ID

    I

    IDType

  25. trait IdType extends AnyRef

    Permalink

    Defines the type of id that a table will have.

    Defines the type of id that a table will have. Right now we have some with Option[Long] and some with UUID

  26. class IgnoreUpdateCompiler extends Phase

    Permalink

    The goal of this compile stage is to remove fields from update statements that should not be updated when using case classes.

    The goal of this compile stage is to remove fields from update statements that should not be updated when using case classes. This is useful for updating using a case class and ignoring indexed fields, which would cause a deadlock. This only removes fields from updating using a case class, sqlu and updating specific fields are not affected by this compiler.

    How it works: 1. Assumes ResultSetMapping state (probably after hoistClientOps). 2. Looks for fields in "from" with column option of IgnoreFieldForUpdate. Removes those. 3. Removes from mapper fields with same ordinal position as fields in #2. 4. Creates a new "wrapper" function around mapper (mapper function goes from case class to tuple) that will create a tuple without ignored fields.

  27. class JdbcTypeImplicits[P <: JdbcProfile] extends AnyRef

    Permalink
  28. trait JdbcTypes[P <: JdbcProfile] extends AnyRef

    Permalink
  29. trait MySQLDAO[T <: MySQLDAOTable[V, I], V <: IdModel[I], I <: IdType] extends DAO[T, V, I, DAOMySQLProfile] with DbImplicits

    Permalink
  30. abstract class MySQLDAOTable[V <: IdModel[I], I <: IdType] extends dao.DAOMySQLProfile.Table[V] with IdTable[I] with DbImplicits

    Permalink
  31. trait MySQLIdModel[I <: IdType] extends IdModel[I] with DbImplicits

    Permalink
  32. case class NewAndOriginal[V](newObject: V, originalObject: V) extends Product with Serializable

    Permalink

    Simple wrapper to pass new and original objects.

    Simple wrapper to pass new and original objects. Using a case class makes it more explicit so you know which is new and which is original

  33. class NoopFormValidator[T] extends DAOFormValidator[T]

    Permalink
  34. trait PostgresDAO[T <: PostgresDAOTable[V, I], V <: IdModel[I], I <: IdType] extends DAO[T, V, I, PostgresProfile] with DbImplicits

    Permalink
  35. abstract class PostgresDAOTable[V <: IdModel[I], I <: IdType] extends slick.jdbc.PostgresProfile.Table[V] with IdTable[I] with DbImplicits

    Permalink
  36. trait PostgresIdModel[I <: IdType] extends IdModel[I] with DbImplicits

    Permalink
  37. trait SoftDelete[T <: Table[V, I, P], V <: IdModel[I], I <: IdType, P <: JdbcProfile, D] extends DAO[T, V, I, P] with SoftDeleteFilter[T, V, I, P, D]

    Permalink
  38. trait SoftDeleteFilter[T <: Table[V, I, P], V <: IdModel[I], I <: IdType, P <: JdbcProfile, D] extends DefaultFilter[T, V, I, P]

    Permalink
  39. trait SoftDeleteFilterOptional[T <: Table[V, I, P], V <: IdModel[I], I <: IdType, P <: JdbcProfile, D] extends DefaultFilter[T, V, I, P]

    Permalink
  40. trait SoftDeleteOptional[T <: Table[V, I, P], V <: IdModel[I], I <: IdType, P <: JdbcProfile, D] extends DAO[T, V, I, P] with SoftDeleteFilterOptional[T, V, I, P, D]

    Permalink

Value Members

  1. object DAOH2Profile extends DAOH2Profile

    Permalink
  2. object DAOMySQLProfile extends DAOMySQLProfile

    Permalink
  3. object DAOTable

    Permalink
  4. object DbLongOptId extends Serializable

    Permalink
  5. object DbUUID extends Serializable

    Permalink
  6. object ExtraColumnOption

    Permalink
  7. object IgnoreFieldForUpdate extends Mode with Product with Serializable

    Permalink
  8. object JdbcTypeImplicits

    Permalink

Ungrouped