com.websudos.morpheus.dsl

DefaultImportsDefinition

trait DefaultImportsDefinition extends LowPriorityImplicits with ModifyImplicits with DefaultForeignKeyConstraints with CreateImplicits

As the implementation of SQL builders may differ depending on the type of SQL database in use, we will provide a series of specific imports for each individual database.

For instance, for MySQL a user will import com.websudos.morpheus.MySQL.Imports._, for Postgress the user will import com.websudos.morpheus .Postgres.Imports._ and so on. To make our life easy when we reach the point of writing disjoint import objects for the various SQL databases, this trait will provide the base implementation of an "all you can eat" imports object.

This includes the various conversions and implicit mechanisms which will have there own underlying structure. As any underlying variable implementation between databases will still extend the same base implementations internally, we can easily override with the settings we need in any place we want.

Thanks to Scala's ability to override the below type aliases, we can easily swap out the base BaseTable implementation for a MySQL specific BaseTable implementation in a manner that's completely invisible to the API user. The naming of things can stay the same while morpheus invisibly implements all necessary discrepancies.

Linear Supertypes
CreateImplicits, DefaultSQLEngines, DefaultForeignKeyConstraints, ModifyImplicits, JoinImplicits, LowPriorityImplicits, AnyRef, Any
Known Subclasses
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. DefaultImportsDefinition
  2. CreateImplicits
  3. DefaultSQLEngines
  4. DefaultForeignKeyConstraints
  5. ModifyImplicits
  6. JoinImplicits
  7. LowPriorityImplicits
  8. AnyRef
  9. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Type Members

  1. type Autoincrement = keys.Autoincrement

  2. type BaseTable[Owner <: BaseTable[Owner, Record], Record] = dsl.BaseTable[Owner, Record]

  3. type BlobColumn[Owner <: BaseTable[Owner, Record], Record] = column.BlobColumn[Owner, Record]

  4. type CharColumn[Owner <: BaseTable[Owner, Record], Record] = column.CharColumn[Owner, Record]

  5. type ForeignKey[Owner <: BaseTable[Owner, Record], Record, T1 <: BaseTable[T1, _]] = column.ForeignKey[Owner, Record, T1]

  6. type Index[Owner <: BaseTable[Owner, Record], Record] = column.Index[Owner, Record]

  7. type IntColumn[Owner <: BaseTable[Owner, Record], Record] = column.IntColumn[Owner, Record]

  8. implicit class JoinColumn[T] extends AnyRef

    Definition Classes
    JoinImplicits
  9. type LongBlobColumn[Owner <: BaseTable[Owner, Record], Record] = column.LongBlobColumn[Owner, Record]

  10. type LongColumn[Owner <: BaseTable[Owner, Record], Record] = column.PrimitiveColumn[Owner, Record, Long]

  11. type LongTextColumn[Owner <: BaseTable[Owner, Record], Record] = column.LongTextColumn[Owner, Record]

  12. type MediumBlobColumn[Owner <: BaseTable[Owner, Record], Record] = column.MediumBlobColumn[Owner, Record]

  13. type MediumIntColumn[Owner <: BaseTable[Owner, Record], Record] = column.MediumIntColumn[Owner, Record]

  14. type MediumTextColumn[Owner <: BaseTable[Owner, Record], Record] = column.MediumTextColumn[Owner, Record]

  15. implicit class ModifyColumn[RR] extends AbstractModifyColumn[RR]

    Definition Classes
    ModifyImplicits
  16. type NotNull = keys.NotNull

  17. implicit class OrderingColumn[RR] extends AbstractOrderingColumn[RR]

    Definition Classes
    ModifyImplicits
  18. type PrimaryKey[ValueType] = keys.PrimaryKey[ValueType]

  19. type PrimitiveColumn[Owner <: BaseTable[Owner, Record], Record, ValueType] = column.PrimitiveColumn[Owner, Record, ValueType]

  20. type Result = morpheus.Result

  21. type Row = morpheus.Row

  22. type SQLPrimitive[T] = morpheus.SQLPrimitive[T]

  23. implicit class SelectColumnRequired[Owner <: dsl.BaseTable[Owner, Record], Record, T] extends SelectColumn[T]

    Definition Classes
    ModifyImplicits
  24. type SmallIntColumn[Owner <: BaseTable[Owner, Record], Record] = column.SmallIntColumn[Owner, Record]

  25. type TextColumn[Owner <: BaseTable[Owner, Record], Record] = column.TextColumn[Owner, Record]

  26. type TinyBlobColumn[Owner <: BaseTable[Owner, Record], Record] = column.TinyBlobColumn[Owner, Record]

  27. type TinyIntColumn[Owner <: BaseTable[Owner, Record], Record] = column.TinyIntColumn[Owner, Record]

  28. type TinyTextColumn[Owner <: BaseTable[Owner, Record], Record] = column.TinyTextColumn[Owner, Record]

  29. type UniqueKey[ValueType] = keys.UniqueKey[ValueType]

  30. type VarcharColumn[Owner <: BaseTable[Owner, Record], Record] = column.VarcharColumn[Owner, Record]

  31. type YearColumn[Owner <: BaseTable[Owner, Record], Record] = column.YearColumn[Owner, Record]

  32. type Zerofill[ValueType] = keys.Zerofill[ValueType]

Abstract Value Members

  1. implicit abstract def columnToQueryColumn[T](col: AbstractColumn[T])(implicit arg0: SQLPrimitive[T]): AbstractQueryColumn[T]

Concrete 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. object Archive extends SQLEngine with Product with Serializable

    Definition Classes
    DefaultSQLEngines
  7. object BDB extends SQLEngine with Product with Serializable

    Definition Classes
    DefaultSQLEngines
  8. object BerkleyDB extends SQLEngine with Product with Serializable

    Definition Classes
    DefaultSQLEngines
  9. object Blackhole extends SQLEngine with Product with Serializable

    Definition Classes
    DefaultSQLEngines
  10. implicit def Boolean2booleanNullConflict(x: Null): Boolean

    Definition Classes
    LowPriorityImplicits
  11. implicit def Byte2byteNullConflict(x: Null): Byte

    Definition Classes
    LowPriorityImplicits
  12. object CSV extends SQLEngine with Product with Serializable

    Definition Classes
    DefaultSQLEngines
  13. object Cascade extends ForeignKeyConstraint with Product with Serializable

    Definition Classes
    DefaultForeignKeyConstraints
  14. implicit def Character2charNullConflict(x: Null): Char

    Definition Classes
    LowPriorityImplicits
  15. implicit def Double2doubleNullConflict(x: Null): Double

    Definition Classes
    LowPriorityImplicits
  16. object Example extends SQLEngine with Product with Serializable

    Definition Classes
    DefaultSQLEngines
  17. object Federated extends SQLEngine with Product with Serializable

    Definition Classes
    DefaultSQLEngines
  18. implicit def Float2floatNullConflict(x: Null): Float

    Definition Classes
    LowPriorityImplicits
  19. object Heap extends SQLEngine with Product with Serializable

    Definition Classes
    DefaultSQLEngines
  20. object InnoBase extends SQLEngine with Product with Serializable

    Definition Classes
    DefaultSQLEngines
  21. object InnoDB extends SQLEngine with Product with Serializable

    Definition Classes
    DefaultSQLEngines
  22. implicit def Integer2intNullConflict(x: Null): Int

    Definition Classes
    LowPriorityImplicits
  23. implicit def Long2longNullConflict(x: Null): Long

    Definition Classes
    LowPriorityImplicits
  24. object Memory extends SQLEngine with Product with Serializable

    Definition Classes
    DefaultSQLEngines
  25. object Merge extends SQLEngine with Product with Serializable

    Definition Classes
    DefaultSQLEngines
  26. object NDB extends SQLEngine with Product with Serializable

    Definition Classes
    DefaultSQLEngines
  27. object NDBCluster extends SQLEngine with Product with Serializable

    Definition Classes
    DefaultSQLEngines
  28. object NoAction extends ForeignKeyConstraint with Product with Serializable

    Definition Classes
    DefaultForeignKeyConstraints
  29. object Restrict extends ForeignKeyConstraint with Product with Serializable

    Definition Classes
    DefaultForeignKeyConstraints
  30. object SetNull extends ForeignKeyConstraint with Product with Serializable

    Definition Classes
    DefaultForeignKeyConstraints
  31. implicit def Short2shortNullConflict(x: Null): Short

    Definition Classes
    LowPriorityImplicits
  32. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  33. implicit def assignmentToQuery[T <: dsl.BaseTable[T, _], R, G <: GroupBind, O <: OrderBind, L <: LimitBind, C <: ChainBind, AC <: AssignBind, Status <: StatusBind](assignment: AssignmentsQuery[T, R, UpdateType, G, O, L, C, AC, Status]): Query[T, R, UpdateType, G, O, L, C, AssignChainned, Terminated]

    Definition Classes
    ModifyImplicits
  34. implicit def booleanWrapper(x: Boolean): RichBoolean

    Definition Classes
    LowPriorityImplicits
    Annotations
    @inline()
  35. implicit def byteWrapper(x: Byte): RichByte

    Definition Classes
    LowPriorityImplicits
    Annotations
    @inline()
  36. implicit def charWrapper(c: Char): RichChar

    Definition Classes
    LowPriorityImplicits
    Annotations
    @inline()
  37. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  38. implicit def createQueryToQuery[T <: dsl.BaseTable[T, _], R, G <: GroupBind, O <: OrderBind, L <: LimitBind, C <: ChainBind, AC <: AssignBind, Status <: StatusBind](assignment: CreateQuery[T, R, CreateType, G, O, L, C, AC, Status]): Query[T, R, CreateType, G, O, L, C, AC, Terminated]

    Definition Classes
    ModifyImplicits
  39. implicit def doubleWrapper(x: Double): RichDouble

    Definition Classes
    LowPriorityImplicits
    Annotations
    @inline()
  40. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  41. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  42. implicit def fallbackStringCanBuildFrom[T]: CanBuildFrom[String, T, IndexedSeq[T]]

    Definition Classes
    LowPriorityImplicits
  43. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  44. implicit def floatWrapper(x: Float): RichFloat

    Definition Classes
    LowPriorityImplicits
    Annotations
    @inline()
  45. implicit def genericWrapArray[T](xs: Array[T]): WrappedArray[T]

    Definition Classes
    LowPriorityImplicits
  46. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  47. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  48. implicit def insertQueryToQuery[T <: dsl.BaseTable[T, _], R, G <: GroupBind, O <: OrderBind, L <: LimitBind, C <: ChainBind, AC <: AssignBind, Status <: StatusBind](assignment: InsertQuery[T, R, InsertType, G, O, L, C, AC, Status]): Query[T, R, InsertType, G, O, L, C, AC, Terminated]

    Definition Classes
    ModifyImplicits
  49. implicit def intWrapper(x: Int): RichInt

    Definition Classes
    LowPriorityImplicits
    Annotations
    @inline()
  50. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  51. implicit def longWrapper(x: Long): RichLong

    Definition Classes
    LowPriorityImplicits
    Annotations
    @inline()
  52. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  53. final def notify(): Unit

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

    Definition Classes
    AnyRef
  55. implicit def queryInsertQuery[T <: dsl.BaseTable[T, _], R, G <: GroupBind, O <: OrderBind, L <: LimitBind, C <: ChainBind, AC <: AssignBind, Status <: StatusBind](query: Query[T, R, InsertType, G, O, L, C, AC, Status]): InsertQuery[T, R, InsertType, G, O, L, C, AC, Status]

    Definition Classes
    ModifyImplicits
  56. implicit def queryToAssignmentsQuery[T <: dsl.BaseTable[T, _], R, G <: GroupBind, O <: OrderBind, L <: LimitBind, C <: ChainBind, AC <: AssignBind, Status <: StatusBind](query: Query[T, R, UpdateType, G, O, L, C, AC, Status]): AssignmentsQuery[T, R, UpdateType, G, O, L, C, AC, Status]

    Definition Classes
    ModifyImplicits
  57. implicit def queryToCreateQuery[T <: dsl.BaseTable[T, _], R, G <: GroupBind, O <: OrderBind, L <: LimitBind, C <: ChainBind, AC <: AssignBind, Status <: StatusBind](query: Query[T, R, CreateType, G, O, L, C, AC, Status]): CreateQuery[T, R, CreateType, G, O, L, C, AC, Status]

    Definition Classes
    ModifyImplicits
  58. implicit def queryToSelectQuery[T <: dsl.BaseTable[T, _], R, G <: GroupBind, O <: OrderBind, L <: LimitBind, C <: ChainBind, AC <: AssignBind, Status <: StatusBind](query: Query[T, R, SelectType, G, O, L, C, AC, Status]): SelectQuery[T, R, SelectType, G, O, L, C, AC, Status]

    Definition Classes
    ModifyImplicits
  59. implicit def rootCreateQueryToCreateQuery[T <: dsl.BaseTable[T, _], R](root: RootCreateQuery[T, R]): CreateQuery[T, R, CreateType, Ungroupped, Unordered, Unlimited, Unchainned, AssignUnchainned, Unterminated]

    This defines an implicit conversion from a RootInsertQuery to an InsertQuery, making the INSERT syntax block invisible to the end user.

    This defines an implicit conversion from a RootInsertQuery to an InsertQuery, making the INSERT syntax block invisible to the end user. This allows chaining a "value" method call directly after "Table.insert".

    T

    The table owning the record.

    R

    The record type.

    root

    The RootSelectQuery to convert.

    returns

    An executable SelectQuery.

    Definition Classes
    CreateImplicits
  60. implicit def rootCreateQueryToQuery[T <: dsl.BaseTable[T, _], R](root: RootCreateQuery[T, R]): Query[T, R, CreateType, Ungroupped, Unordered, Unlimited, Unchainned, AssignUnchainned, Unterminated]

    Definition Classes
    ModifyImplicits
  61. implicit def rootDeleteQueryToDeleteQuery[T <: dsl.BaseTable[T, _], R](root: RootDeleteQuery[T, R]): Query[T, R, DeleteType, Ungroupped, Unordered, Unlimited, Unchainned, AssignUnchainned, Unterminated]

    This defines an implicit conversion from a RootUpdateQuery to an UpdateQuery, making the UPDATE syntax block invisible to the end user.

    This defines an implicit conversion from a RootUpdateQuery to an UpdateQuery, making the UPDATE syntax block invisible to the end user. Much like a decision block, a UpdateSyntaxBlock needs a decision branch to follow, may that be nothing, LOW_PRIORITY or IGNORE.

    The one catch is that this form of "exit" from an un-executable RootUpdateQuery will directly translate the query to an "UPDATE tableName" query, meaning no UPDATE operators will be used in the default serialisation.

    The simple assumption made here is that since the user didn't use any other provided method, such as "lowPriority" or "ignore" the desired behaviour is a full select.

    T

    The table owning the record.

    R

    The record type.

    root

    The RootSelectQuery to convert.

    returns

    An executable SelectQuery.

    Definition Classes
    ModifyImplicits
  62. implicit def rootInsertQueryToInsertQuery[T <: dsl.BaseTable[T, _], R](root: RootInsertQuery[T, R]): InsertQuery[T, R, InsertType, Ungroupped, Unordered, Unlimited, Unchainned, AssignUnchainned, Unterminated]

    This defines an implicit conversion from a RootInsertQuery to an InsertQuery, making the INSERT syntax block invisible to the end user.

    This defines an implicit conversion from a RootInsertQuery to an InsertQuery, making the INSERT syntax block invisible to the end user. This allows chaining a "value" method call directly after "Table.insert".

    T

    The table owning the record.

    R

    The record type.

    root

    The RootSelectQuery to convert.

    returns

    An executable SelectQuery.

    Definition Classes
    ModifyImplicits
  63. implicit def rootInsertQueryToQuery[T <: dsl.BaseTable[T, _], R](root: RootInsertQuery[T, R]): Query[T, R, InsertType, Ungroupped, Unordered, Unlimited, Unchainned, AssignUnchainned, Unterminated]

    This defines an implicit conversion from a RootInsertQuery to an InsertQuery, making the INSERT syntax block invisible to the end user.

    This defines an implicit conversion from a RootInsertQuery to an InsertQuery, making the INSERT syntax block invisible to the end user. This is used to automatically "exit" the INSERT syntax block with the default "INSERT INTO" option, while picking no other SQL options such as IGNORE or LOW_PRIORITY.

    This is making the following queries equivalent: - Table.insert.into.queryString = "INSERT INTO table" - Table.insert = "INSERT INTO table"

    T

    The table owning the record.

    R

    The record type.

    root

    The RootSelectQuery to convert.

    returns

    An executable SelectQuery.

    Definition Classes
    ModifyImplicits
  64. implicit def rootSelectQueryToSelectQuery[T <: dsl.BaseTable[T, _], R](root: AbstractRootSelectQuery[T, R]): Query[T, R, SelectType, Ungroupped, Unordered, Unlimited, Unchainned, AssignUnchainned, Unterminated]

    This defines an implicit conversion from a RootSelectQuery to a SelectQuery, making the SELECT syntax block invisible to the end user.

    This defines an implicit conversion from a RootSelectQuery to a SelectQuery, making the SELECT syntax block invisible to the end user. Much like a decision block, a SelectSyntaxBlock needs a decision branch to follow, may that be DISTINCT, ALL or DISTINCTROW as per the SQL spec.

    The one catch is that this form of "exit" from an un-executable RootSelectQuery will directly translate the query to a "SELECT fields* FROM tableName" query, meaning no SELECT operators will be used in the serialisation.

    The simple assumption made here is that since the user didn't use any other provided method, such as "all", "distinct" or "distinctrow", the desired behaviour is a full select.

    T

    The table owning the record.

    R

    The record type.

    root

    The RootSelectQuery to convert.

    returns

    An executable SelectQuery.

    Definition Classes
    ModifyImplicits
  65. implicit def rootUpdateQueryToAssignQuery[T <: dsl.BaseTable[T, _], R](root: RootUpdateQuery[T, R]): AssignmentsQuery[T, R, UpdateType, Ungroupped, Unordered, Unlimited, Unchainned, AssignUnchainned, Unterminated]

    Definition Classes
    ModifyImplicits
  66. implicit def rootUpdateQueryToUpdateQuery[T <: dsl.BaseTable[T, _], R](root: RootUpdateQuery[T, R]): Query[T, R, UpdateType, Ungroupped, Unordered, Unlimited, Unchainned, AssignUnchainned, Unterminated]

    This defines an implicit conversion from a RootUpdateQuery to an UpdateQuery, making the UPDATE syntax block invisible to the end user.

    This defines an implicit conversion from a RootUpdateQuery to an UpdateQuery, making the UPDATE syntax block invisible to the end user. Much like a decision block, a UpdateSyntaxBlock needs a decision branch to follow, may that be nothing, LOW_PRIORITY or IGNORE.

    The one catch is that this form of "exit" from an un-executable RootUpdateQuery will directly translate the query to an "UPDATE tableName" query, meaning no UPDATE operators will be used in the default serialisation.

    The simple assumption made here is that since the user didn't use any other provided method, such as "lowPriority" or "ignore" the desired behaviour is a full select.

    T

    The table owning the record.

    R

    The record type.

    root

    The RootSelectQuery to convert.

    returns

    An executable SelectQuery.

    Definition Classes
    ModifyImplicits
  67. implicit def selectOperatorClauseToSelectColumn[T](clause: SelectOperatorClause[T]): SelectColumn[T]

    Definition Classes
    ModifyImplicits
  68. implicit def selectQueryToQuery[T <: dsl.BaseTable[T, _], R, G <: GroupBind, O <: OrderBind, L <: LimitBind, C <: ChainBind, AC <: AssignBind, Status <: StatusBind](assignment: SelectQuery[T, R, SelectType, G, O, L, C, AC, Status]): Query[T, R, SelectType, G, O, L, C, AC, Terminated]

    Definition Classes
    ModifyImplicits
  69. implicit def shortWrapper(x: Short): RichShort

    Definition Classes
    LowPriorityImplicits
    Annotations
    @inline()
  70. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  71. def toString(): String

    Definition Classes
    AnyRef → Any
  72. implicit def unwrapString(ws: WrappedString): String

    Definition Classes
    LowPriorityImplicits
  73. final def wait(): Unit

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

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

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  76. implicit def wrapBooleanArray(xs: Array[Boolean]): WrappedArray[Boolean]

    Definition Classes
    LowPriorityImplicits
  77. implicit def wrapByteArray(xs: Array[Byte]): WrappedArray[Byte]

    Definition Classes
    LowPriorityImplicits
  78. implicit def wrapCharArray(xs: Array[Char]): WrappedArray[Char]

    Definition Classes
    LowPriorityImplicits
  79. implicit def wrapDoubleArray(xs: Array[Double]): WrappedArray[Double]

    Definition Classes
    LowPriorityImplicits
  80. implicit def wrapFloatArray(xs: Array[Float]): WrappedArray[Float]

    Definition Classes
    LowPriorityImplicits
  81. implicit def wrapIntArray(xs: Array[Int]): WrappedArray[Int]

    Definition Classes
    LowPriorityImplicits
  82. implicit def wrapLongArray(xs: Array[Long]): WrappedArray[Long]

    Definition Classes
    LowPriorityImplicits
  83. implicit def wrapRefArray[T <: AnyRef](xs: Array[T]): WrappedArray[T]

    Definition Classes
    LowPriorityImplicits
  84. implicit def wrapShortArray(xs: Array[Short]): WrappedArray[Short]

    Definition Classes
    LowPriorityImplicits
  85. implicit def wrapString(s: String): WrappedString

    Definition Classes
    LowPriorityImplicits
  86. implicit def wrapUnitArray(xs: Array[Unit]): WrappedArray[Unit]

    Definition Classes
    LowPriorityImplicits

Inherited from CreateImplicits

Inherited from DefaultSQLEngines

Inherited from DefaultForeignKeyConstraints

Inherited from ModifyImplicits

Inherited from JoinImplicits

Inherited from LowPriorityImplicits

Inherited from AnyRef

Inherited from Any

Ungrouped