object query extends Helpers
AST for molecule Query representation.
Molecule transforms custom boilerplate DSL constructs to Datomic queries in 3 steps:
Custom DSL molecule --> Model --> Query --> Datomic query string
- Source
- query.scala
- Alphabetic
- By Inheritance
- query
- Helpers
- DateHandling
- RegexMatching
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Type Members
- case class AggrExpr(fn: String, args: Seq[Any], v: Var) extends Output with Product with Serializable
- sealed trait Binding extends QueryTerm
- sealed trait Clause extends QueryExpr
- case class CollectionBinding(v: Var) extends Binding with Product with Serializable
- case class DS(name: String = "") extends DataSource with Product with Serializable
- case class DataClause(ds: DataSource, e: QueryValue, a: KW, v: QueryValue, tx: QueryTerm, op: QueryTerm = NoBinding) extends Clause with Product with Serializable
- sealed trait DataSource extends QueryTerm
- sealed trait ExpressionClause extends Clause
- case class Find(outputs: Seq[Output]) extends QueryExpr with Product with Serializable
- case class Funct(name: String, ins: Seq[QueryTerm], outs: Binding) extends ExpressionClause with Product with Serializable
- case class In(inputs: Seq[Input], rules: Seq[Rule] = Seq(), ds: Seq[DataSource] = Seq(DS)) extends QueryExpr with Product with Serializable
- case class InDataSource(ds: DataSource, argss: Seq[Seq[Any]] = Seq(Seq())) extends Input with Product with Serializable
- case class InVar(binding: Binding, argss: Seq[Seq[Any]] = Seq(Seq())) extends Input with Product with Serializable
- trait Input extends QueryTerm
- case class KW(nsFull: String, attr: String, refNs: String = "") extends QueryValue with Product with Serializable
- case class NestedAttrs(level: Int, nsFull: String, attr: String, attrSpecs: Seq[PullAttrSpec]) extends PullAttrSpec with Product with Serializable
- case class NotClause(e: Var, a: KW) extends Clause with Product with Serializable
- case class NotClauses(clauses: Seq[Clause]) extends Clause with Product with Serializable
- case class NotJoinClauses(nonUnifyingVars: Seq[Var], clauses: Seq[Clause]) extends Clause with Product with Serializable
- sealed trait Output extends QueryExpr
- case class Placeholder(e: Var, kw: KW, v: Var, enumPrefix: Option[String] = None) extends Input with Product with Serializable
- case class Pull(e: String, nsFull: String, attr: String, enumPrefix: Option[String] = None) extends QueryValue with Output with Product with Serializable
- case class PullAttr(nsFull: String, attr: String, opt: Boolean) extends PullAttrSpec with Product with Serializable
- sealed trait PullAttrSpec extends QueryValue with Output
- case class PullEnum(nsFull: String, attr: String, opt: Boolean) extends PullAttrSpec with Product with Serializable
- case class PullNested(e: String, nestedAttrs: NestedAttrs) extends QueryValue with Output with Product with Serializable
-
case class
Query(f: Find, wi: With, i: In, wh: Where) extends QueryExpr with Product with Serializable
Molecule Query representation.
Molecule Query representation.
Molecule transforms custom boilerplate DSL constructs to Datomic queries in 3 steps:
Custom DSL molecule --> Model --> Query --> Datomic query string
Query is thus derived from Model representation.- f
Find parameters
- wi
With parameters
- i
Input parameters
- wh
Where parameters: data clauses
- trait QueryExpr extends AnyRef
- trait QueryTerm extends QueryExpr
- sealed trait QueryValue extends QueryTerm
- case class RelationBinding(vs: Seq[Var]) extends Binding with Product with Serializable
- case class Rule(name: String, args: Seq[QueryValue], clauses: Seq[Clause]) extends QueryTerm with Product with Serializable
- case class RuleInvocation(name: String, args: Seq[QueryTerm]) extends Clause with Product with Serializable
- case class ScalarBinding(v: Var) extends Binding with Product with Serializable
- case class TupleBinding(vs: Seq[Var]) extends Binding with Product with Serializable
- case class Val(v: Any) extends QueryValue with Output with Product with Serializable
- case class Var(v: String) extends QueryValue with Output with Product with Serializable
- case class Where(clauses: Seq[Clause]) extends QueryExpr with Product with Serializable
- case class With(variables: Seq[String]) extends QueryExpr with Product with Serializable
-
implicit
class
Regex extends AnyRef
- Definition Classes
- RegexMatching
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
cast(value: Any): String
- Attributes
- protected
- Definition Classes
- Helpers
-
def
clean(attr: String): String
- Definition Classes
- Helpers
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
def
date2datomicStr(date: Date, zoneOffset: ZoneOffset = localZoneOffset): String
- Definition Classes
- DateHandling
-
def
date2str(date: Date, zoneOffset: ZoneOffset = localZoneOffset): String
- Definition Classes
- DateHandling
-
def
daylight(ms: Long): Int
- Definition Classes
- DateHandling
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
expandDateStr(dateStr: String): String
- Definition Classes
- DateHandling
-
final
def
f(a: Any): Any
- Attributes
- protected
- Definition Classes
- Helpers
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
lazy val
localOffset: String
- Definition Classes
- DateHandling
-
lazy val
localZoneOffset: ZoneOffset
- Definition Classes
- DateHandling
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
o(opt: Option[Any]): String
- Attributes
- protected
- Definition Classes
- Helpers
-
final
def
os(opt: Option[Set[_]]): String
- Attributes
- protected
- Definition Classes
- Helpers
-
final
def
seq[T](values: Seq[T]): String
- Attributes
- protected
- Definition Classes
- Helpers
-
def
str2date(s: String, zoneOffset: ZoneOffset = localZoneOffset): Date
- Definition Classes
- DateHandling
-
def
str2zdt(s: String, zoneOffset: ZoneOffset = localZoneOffset): ZonedDateTime
- Definition Classes
- DateHandling
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
final
def
time(n: Int, prev: Int = 0): Unit
- Attributes
- protected
- Definition Classes
- Helpers
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
def
truncateDateStr(dateStr: String): String
- Definition Classes
- DateHandling
-
final
def
tupleToSeq(arg: Any): Seq[Any]
- Attributes
- protected
- Definition Classes
- Helpers
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
lazy val
zone: ZoneId
- Definition Classes
- DateHandling
- object DS extends DataSource with Product with Serializable
- object DataClause extends Serializable
- object Empty extends QueryTerm with Product with Serializable
- object ImplDS extends DataSource with Product with Serializable
- object NoBinding extends Binding with Product with Serializable
- object NoVal extends QueryValue with Output with Product with Serializable
- object Query extends Serializable
-
object
mkDate
- Attributes
- protected
- Definition Classes
- Helpers
Documentation/API for the Molecule library - a meta DSL for the Datomic database.
Manual | scalamolecule.org | Github | Forum