Class

com.github.aselab.activerecord.inner.Relations

Relation4

Related Doc: package Relations

Permalink

case class Relation4[T <: AR, J1 <: AR, J2 <: AR, J3 <: AR, S](parameters: Parameters[T, (T, J1, J2, J3), S], queryable: dsl.Queryable[T], joinTable1: dsl.Queryable[J1], joinTable2: dsl.Queryable[J2], joinTable3: dsl.Queryable[J3], on: ((T, J1, J2, J3)) ⇒ (dsl.LogicalBoolean, dsl.LogicalBoolean, dsl.LogicalBoolean))(implicit manifest: ClassTag[T]) extends Relation[T, S] with Product with Serializable

Source
Relations.scala
Linear Supertypes
Serializable, Serializable, Product, Equals, Relation[T, S], QuerySupport[T, S], AnyRef, Any
Type Hierarchy
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Relation4
  2. Serializable
  3. Serializable
  4. Product
  5. Equals
  6. Relation
  7. QuerySupport
  8. AnyRef
  9. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new Relation4(parameters: Parameters[T, (T, J1, J2, J3), S], queryable: dsl.Queryable[T], joinTable1: dsl.Queryable[J1], joinTable2: dsl.Queryable[J2], joinTable3: dsl.Queryable[J3], on: ((T, J1, J2, J3)) ⇒ (dsl.LogicalBoolean, dsl.LogicalBoolean, dsl.LogicalBoolean))(implicit manifest: ClassTag[T])

    Permalink

Type Members

  1. case class GroupRelation1[R](groupScope: (Relation.JoinedType) ⇒ dsl.TypedExpression[R, _], havingConditions: List[(Relation.JoinedType) ⇒ dsl.LogicalBoolean] = Nil) extends Product with Serializable

    Permalink
    Definition Classes
    Relation
  2. type Inc[A <: AR] = (T) ⇒ ActiveRecord.Association[T, A]

    Permalink
    Definition Classes
    QuerySupport
  3. type JoinedType = (T, J1, J2, J3)

    Permalink
    Definition Classes
    Relation4QuerySupport
  4. type TupleN = AnyRef { def _1: T }

    Permalink
    Definition Classes
    QuerySupport

Value Members

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

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

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

    Permalink
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  5. def average[T2 >: dsl.TOptionFloat, T1 <: T2, A1, A2](e: (JoinedType) ⇒ dsl.TypedExpression[A1, T1])(implicit f: dsl.TypedExpressionFactory[A2, T2]): A2

    Permalink
    Definition Classes
    Relation
  6. def avg[T2 >: dsl.TOptionFloat, T1 <: T2, A1, A2](e: (JoinedType) ⇒ dsl.TypedExpression[A1, T1])(implicit f: dsl.TypedExpressionFactory[A2, T2]): A2

    Permalink
    Definition Classes
    Relation
  7. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  8. lazy val companion: ActiveRecordBaseCompanion[_, T]

    Permalink
    Definition Classes
    QuerySupport
  9. def compute[T1](e: (JoinedType) ⇒ dsl.TypedExpression[T1, _]): T1

    Permalink
    Definition Classes
    Relation
  10. def conditions: List[(JoinedType) ⇒ dsl.LogicalBoolean]

    Permalink
    Definition Classes
    QuerySupport
  11. implicit def convertFactory[A](f: dsl.TypedExpressionFactory[A, _]): dsl.TypedExpressionFactory[A, Any]

    Permalink
    Attributes
    protected
    Definition Classes
    Relation
  12. def copyParams[R](params: Parameters[T, JoinedType, R]): Relation4[T, J1, J2, J3, R]

    Permalink
    Attributes
    protected
    Definition Classes
    Relation4QuerySupport
  13. def copyParams[R](conditions: List[(JoinedType) ⇒ dsl.LogicalBoolean] = parameters.conditions, orders: List[(JoinedType) ⇒ dsl.ExpressionNode] = parameters.orders, selector: (JoinedType) ⇒ R = parameters.selector, includeAssociations: List[(T) ⇒ ActiveRecord.Association[T, AR]] = parameters.includeAssociations, pages: Option[(Int, Int)] = parameters.pages, isUnique: Boolean = parameters.isUnique, isReverse: Boolean = parameters.isReverse): Relation[T, R]

    Permalink
    Attributes
    protected
    Definition Classes
    QuerySupport
  14. def count: Long

    Permalink
    Definition Classes
    Relation
  15. def deleteAll()(implicit ev: =:=[S, T]): List[T]

    Permalink
    Definition Classes
    Relation
  16. def distinct: Relation4.this.type

    Permalink
    Definition Classes
    QuerySupport
  17. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  18. def exists(condition: (T) ⇒ dsl.LogicalBoolean): Boolean

    Permalink
    Definition Classes
    Relation
  19. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  20. macro def find(id: Any): Option[S]

    Permalink
    Definition Classes
    Relation
  21. macro def findAllBy(name: String, value: Any): Relation4.this.type

    Permalink

    Search by fieldname and value.

    Search by fieldname and value.

    findAllBy("name", "abc")
    name

    field name

    value

    field value

    Definition Classes
    Relation
  22. macro def findAllBy(conditions: (String, Any)*): Relation4.this.type

    Permalink

    Search by multiple fieldnames and values.

    Search by multiple fieldnames and values.

    findAllBy("name" -> "abc", "email" -> "[email protected]")
    conditions

    fieldname-value tuples

    Definition Classes
    Relation
  23. macro def findBy(name: String, value: Any): Option[S]

    Permalink

    Search by fieldname and value and return first record.

    Search by fieldname and value and return first record.

    findBy("name", "abc")
    name

    field name

    value

    field value

    Definition Classes
    Relation
  24. macro def findBy(conditions: (String, Any)*): Option[S]

    Permalink

    Search by multiple fieldnames and values and return first record.

    Search by multiple fieldnames and values and return first record.

    findBy("name" -> "abc", "email" -> "[email protected]")
    conditions

    fieldname-value tuples

    Definition Classes
    Relation
  25. macro def findByOrCreate(m: T, fields: String*): S

    Permalink
    Definition Classes
    Relation
  26. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  27. def group[R](groupScope: (JoinedType) ⇒ dsl.TypedExpression[R, _]): GroupRelation1[R]

    Permalink
    Definition Classes
    Relation
  28. def head: S

    Permalink
    Definition Classes
    Relation
  29. def headOption: Option[S]

    Permalink
    Definition Classes
    Relation
  30. def includeAssociations: List[(T) ⇒ ActiveRecord.Association[T, AR]]

    Permalink
    Definition Classes
    QuerySupport
  31. def includes[A1 <: AR, A2 <: AR, A3 <: AR, A4 <: AR](a1: Inc[A1], a2: Inc[A2], a3: Inc[A3], a4: Inc[A4]): Relation4.this.type

    Permalink
    Definition Classes
    QuerySupport
  32. def includes[A1 <: AR, A2 <: AR, A3 <: AR](a1: Inc[A1], a2: Inc[A2], a3: Inc[A3]): Relation4.this.type

    Permalink
    Definition Classes
    QuerySupport
  33. def includes[A1 <: AR, A2 <: AR](a1: Inc[A1], a2: Inc[A2]): Relation4.this.type

    Permalink
    Definition Classes
    QuerySupport
  34. def includes[A <: AR](association: Inc[A]): Relation4.this.type

    Permalink
    Definition Classes
    QuerySupport
  35. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  36. def isLoaded: Boolean

    Permalink
    Definition Classes
    Relation
  37. def isReverse: Boolean

    Permalink
    Definition Classes
    QuerySupport
  38. def isUnique: Boolean

    Permalink
    Definition Classes
    QuerySupport
  39. val joinTable1: dsl.Queryable[J1]

    Permalink
  40. val joinTable2: dsl.Queryable[J2]

    Permalink
  41. val joinTable3: dsl.Queryable[J3]

    Permalink
  42. def last: S

    Permalink
    Definition Classes
    Relation
  43. def lastOption: Option[S]

    Permalink
    Definition Classes
    Relation
  44. def limit(count: Int): Relation4.this.type

    Permalink

    returns limited results.

    returns limited results.

    Post.all.orderBy(p => p.updatedAt desc).limit(10)
    count

    max count

    Definition Classes
    QuerySupport
  45. def load(implicit m: ClassTag[S]): List[S]

    Permalink
    Definition Classes
    Relation
  46. implicit val manifest: ClassTag[T]

    Permalink
    Definition Classes
    Relation4QuerySupport
  47. def max[T2 >: dsl.TOption, T1 <: T2, A1, A2](e: (JoinedType) ⇒ dsl.TypedExpression[A1, T1])(implicit f: dsl.TypedExpressionFactory[A2, T2]): A2

    Permalink
    Definition Classes
    Relation
  48. def maximum[T2 >: dsl.TOption, T1 <: T2, A1, A2](e: (JoinedType) ⇒ dsl.TypedExpression[A1, T1])(implicit f: dsl.TypedExpressionFactory[A2, T2]): A2

    Permalink
    Definition Classes
    Relation
  49. def min[T2 >: dsl.TOption, T1 <: T2, A1, A2](e: (JoinedType) ⇒ dsl.TypedExpression[A1, T1])(implicit f: dsl.TypedExpressionFactory[A2, T2]): A2

    Permalink
    Definition Classes
    Relation
  50. def minimum[T2 >: dsl.TOption, T1 <: T2, A1, A2](e: (JoinedType) ⇒ dsl.TypedExpression[A1, T1])(implicit f: dsl.TypedExpressionFactory[A2, T2]): A2

    Permalink
    Definition Classes
    Relation
  51. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  52. def not(condition: (T) ⇒ dsl.LogicalBoolean): Relation4.this.type

    Permalink
    Definition Classes
    QuerySupport
  53. final def notify(): Unit

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

    Permalink
    Definition Classes
    AnyRef
  55. val on: ((T, J1, J2, J3)) ⇒ (dsl.LogicalBoolean, dsl.LogicalBoolean, dsl.LogicalBoolean)

    Permalink
  56. def orderBy(conditions: (T, J1, J2, J3) ⇒ dsl.ExpressionNode*): Relation4.this.type

    Permalink
  57. def orderBy(name: String, order: String): Relation4.this.type

    Permalink
    Definition Classes
    Relation
  58. def orderBy(conditions: (T) ⇒ dsl.ExpressionNode*): Relation4.this.type

    Permalink
    Definition Classes
    QuerySupport
  59. def orders: List[(JoinedType) ⇒ dsl.ExpressionNode]

    Permalink
    Definition Classes
    QuerySupport
  60. def ordersExpression(m: JoinedType): List[dsl.ExpressionNode]

    Permalink
    Attributes
    protected
    Definition Classes
    QuerySupport
  61. def page(offset: Int, count: Int): Relation4.this.type

    Permalink

    returns page results.

    returns page results.

    Post.all.orderBy(p => p.updatedAt desc).page(10 * (pageNumber - 1), 10)
    offset

    offset count

    count

    max count

    Definition Classes
    QuerySupport
  62. def pages: Option[(Int, Int)]

    Permalink
    Definition Classes
    QuerySupport
  63. def paginate[R](query: dsl.Query[R]): Query[R]

    Permalink
    Attributes
    protected
    Definition Classes
    QuerySupport
  64. val parameters: Parameters[T, (T, J1, J2, J3), S]

    Permalink
    Definition Classes
    Relation4QuerySupport
  65. val queryable: dsl.Queryable[T]

    Permalink
    Definition Classes
    Relation4Relation
  66. implicit def relationToThisType[R](self: Relation[T, R]): Relation4.this.type

    Permalink
    Attributes
    protected
    Definition Classes
    QuerySupport
  67. def reload(implicit m: ClassTag[S]): List[S]

    Permalink
    Definition Classes
    Relation
  68. def reverse: Relation4.this.type

    Permalink
    Definition Classes
    QuerySupport
  69. def reverseOrder(m: JoinedType): List[dsl.OrderByExpression]

    Permalink
    Attributes
    protected
    Definition Classes
    QuerySupport
  70. def select[R](selector: (T, J1, J2, J3) ⇒ R): Relation[T, R]

    Permalink
  71. def select[R](selector: (T) ⇒ R): Relation[T, R]

    Permalink
    Definition Classes
    QuerySupport
  72. def selector: (JoinedType) ⇒ S

    Permalink
    Definition Classes
    QuerySupport
  73. def sum[T2 >: dsl.TOption, T1 >: dsl.TNumericLowerTypeBound <: T2, A1, A2](e: (JoinedType) ⇒ dsl.TypedExpression[A1, T1])(implicit f: dsl.TypedExpressionFactory[A2, T2]): A2

    Permalink
    Definition Classes
    Relation
  74. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  75. def toQuery[R](f: (JoinedType) ⇒ dsl.QueryYield[R]): dsl.Query[R]

    Permalink
    Attributes
    protected
    Definition Classes
    Relation4Relation
  76. def toQuery: dsl.Query[S]

    Permalink
    Definition Classes
    Relation
  77. def toSql: String

    Permalink
    Definition Classes
    Relation
  78. def unsafeFindAllBy(condition: (String, Any), conditions: (String, Any)*): Relation4.this.type

    Permalink

    Search by fieldname and value.

    Search by fieldname and value.

    unsafeFindAllBy("name", "abc")
    Definition Classes
    Relation
  79. def unsafeFindAllBy(name: String, value: Any): Relation4.this.type

    Permalink

    Search by fieldname and value.

    Search by fieldname and value.

    unsafeFindAllBy("name", "abc")
    name

    field name

    value

    field value

    Definition Classes
    Relation
  80. def unsafeFindBy(condition: (String, Any), conditions: (String, Any)*): Option[S]

    Permalink

    Search by multiple fieldnames and values and return first record.

    Search by multiple fieldnames and values and return first record.

    unsafeFindBy("name" -> "abc", "email" -> "[email protected]")
    condition

    fieldname-value tuple

    conditions

    multiple fieldname-value tuples(optional)

    Definition Classes
    Relation
  81. def unsafeFindByOrCreate(m: T, field: String, fields: String*)(implicit ev: =:=[T, S]): S

    Permalink
    Definition Classes
    Relation
  82. final def wait(): Unit

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

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

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  85. def where(condition: (T, J1, J2, J3) ⇒ dsl.LogicalBoolean): Relation4.this.type

    Permalink
  86. def where(condition: (T) ⇒ dsl.LogicalBoolean): Relation4.this.type

    Permalink
    Definition Classes
    QuerySupport
  87. def whereScope(m: JoinedType): WhereState[_ >: Unconditioned with Conditioned <: AnyRef]

    Permalink
    Attributes
    protected
    Definition Classes
    QuerySupport
  88. def wrap[A <: TupleN, R](f: (T) ⇒ R): (A) ⇒ R

    Permalink
    Attributes
    protected
    Definition Classes
    QuerySupport
  89. def wrapTuple1[A <: TupleN, R](f: ((T)) ⇒ R): (A) ⇒ R

    Permalink
    Attributes
    protected
    Definition Classes
    QuerySupport

Inherited from Serializable

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from Relation[T, S]

Inherited from QuerySupport[T, S]

Inherited from AnyRef

Inherited from Any

Ungrouped