skinny.orm.feature

associations

package associations

Visibility
  1. Public
  2. All

Type Members

  1. sealed trait Association[Entity] extends AnyRef

    Association.

    Association.

    Entity

    entity

  2. case class BelongsToAssociation[Entity](mapper: AssociationsFeature[Entity], joinDefinitions: LinkedHashSet[JoinDefinition[_]], extractor: BelongsToExtractor[Entity]) extends Association[Entity] with Product with Serializable

    BelongsTo relation.

    BelongsTo relation.

    Entity

    entity

    mapper

    mapper

    joinDefinitions

    join definitions

    extractor

    extractor

  3. case class BelongsToExtractor[Entity](mapper: AssociationsFeature[_], fk: String, alias: Alias[_], merge: (Entity, Option[Any]) ⇒ Entity, includesMerge: (Seq[Entity], Seq[_]) ⇒ Seq[Entity] = ..., byDefault: Boolean = false) extends Extractor[Entity] with Product with Serializable

    BelongsTo association extractor.

    BelongsTo association extractor.

    Entity

    entity

    mapper

    mapper

    fk

    foreign key

    alias

    table alias

    merge

    function to merge associations

    byDefault

    enable by default

  4. sealed trait Extractor[Entity] extends AnyRef

    Extractor.

    Extractor.

    Entity

    entity

  5. case class HasManyAssociation[Entity](mapper: AssociationsFeature[Entity], joinDefinitions: LinkedHashSet[JoinDefinition[_]], extractor: HasManyExtractor[Entity]) extends Association[Entity] with Product with Serializable

    HasMany association.

    HasMany association.

    Entity

    entity

    mapper

    mapper

    joinDefinitions

    join definitions

    extractor

    extractor

  6. case class HasManyExtractor[Entity](mapper: AssociationsFeature[_], alias: Alias[_], merge: (Entity, Seq[Any]) ⇒ Entity, includesMerge: (Seq[Entity], Seq[_]) ⇒ Seq[Entity] = ..., byDefault: Boolean = false) extends Extractor[Entity] with Product with Serializable

    HasMany association extractor.

    HasMany association extractor.

    Entity

    entity

    mapper

    mapper

    alias

    table alias

    merge

    function to merge associations

    byDefault

    enable by default

  7. case class HasOneAssociation[Entity](mapper: AssociationsFeature[Entity], joinDefinitions: LinkedHashSet[JoinDefinition[_]], extractor: HasOneExtractor[Entity]) extends Association[Entity] with Product with Serializable

    HasOne association.

    HasOne association.

    Entity

    entity

    mapper

    mapper

    joinDefinitions

    join definitions

    extractor

    extractor

  8. case class HasOneExtractor[Entity](mapper: AssociationsFeature[_], fk: String, alias: Alias[_], merge: (Entity, Option[Any]) ⇒ Entity, includesMerge: (Seq[Entity], Seq[_]) ⇒ Seq[Entity] = ..., byDefault: Boolean = false) extends Extractor[Entity] with Product with Serializable

    HasOne association extractor.

    HasOne association extractor.

    Entity

    entity

    mapper

    mapper

    fk

    foreign key

    alias

    table alias

    merge

    function to merge associations

    byDefault

    enable by default

  9. case class JoinDefinition[Entity](joinType: JoinType, thisMapper: AssociationsFeature[Entity], leftMapper: AssociationsFeature[Any], leftAlias: Alias[Any], rightMapper: AssociationsFeature[Any], rightAlias: Alias[Any], on: scalikejdbc.SQLSyntax, fk: Option[(Any) ⇒ Option[Long]] = None, enabledEvenIfAssociated: Boolean = false, enabledByDefault: Boolean = false) extends Product with Serializable

    Join definition.

    Join definition.

    Entity

    entity

    joinType

    join type (innerJoin/LeftOuterJoin)

    thisMapper

    this mapper

    leftMapper

    left mapper

    leftAlias

    left table alias

    rightMapper

    right mapper

    rightAlias

    right table alias

    on

    join condition

    fk

    foreign key to join

    enabledEvenIfAssociated

    enable even if the right one is associated

    enabledByDefault

    enable by default

  10. sealed trait JoinType extends AnyRef

    Join type.

Value Members

  1. object InnerJoin extends JoinType with Product with Serializable

    Inner join.

  2. object LeftOuterJoin extends JoinType with Product with Serializable

    Left (outer) join.

Ungrouped