Packages

  • package root
    Definition Classes
    root
  • package molecule
    Definition Classes
    root
  • package api
    Definition Classes
    molecule
  • package ast
    Definition Classes
    molecule
  • package exceptions

    Exceptions thrown by Molecule.

    Exceptions thrown by Molecule.

    Definition Classes
    molecule
  • package ops

    Internal operational helpers for transforming DSL to molecules.

    Internal operational helpers for transforming DSL to molecules.

    Definition Classes
    molecule
  • package schema

    Schema definition DSL and API.

    Schema definition DSL and API.

    Definition Classes
    molecule
  • SchemaTransaction
  • definition
  • package transform

    Internal transformers from DSL to Model/Query/Transaction/Datomic.

    Internal transformers from DSL to Model/Query/Transaction/Datomic.

    Molecule transforms custom boilerplate DSL constructs to Datomic queries in 3 steps:

    Custom DSL molecule --> Model --> Query --> Datomic query string

    Definition Classes
    molecule
    See also

    http://www.scalamolecule.org/dev/transformation/

  • package util

    Internal database functions for Datomic.

    Internal database functions for Datomic.

    Definition Classes
    molecule

package schema

Schema definition DSL and API.

Source
package.scala
Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. schema
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Type Members

  1. trait SchemaTransaction extends AnyRef

    Schema transaction interface for auto-generated schema transaction data.

    Schema transaction interface for auto-generated schema transaction data.

    See also

    Manual

Value Members

  1. object definition

    Schema definition DSL.

    Schema definition DSL.

    Define Datomic database schema in a Schema Definition file.

    For small projects, the schema can be defined without partition definitions where all namespaces reside in a default tacit partition:

    package path.to.your.project
    import molecule.schema.definition._       // import schema definition DSL
    
    @InOut(1, 8)                              // Set input/output arity
    object SeattleDefinition {                // Schema definition object
    
      trait Person {                          // Namespace
        val name = oneString.fulltext   // String attribute definition with fulltext search
        val age  = oneInt                     // Int attribute definition
      }
    
      // Additional namespaces...
    }

    For larger projects, it is recommended to group namespaces in partitions:

    package path.to.your.project
    import molecule.schema.definition._
    
    @InOut(3, 15)
    object SeattleDefinition {
    
      object customer {
        trait Person {
          val name    = oneString.fulltext
          val age     = oneInt
          val address = one[Address]
          val bought  = many[products.Item]
        }
        trait Address {
          val street = oneString.fulltext
          val city   = oneInt
        }
        // ..more namespaces in the `customer` partition
      }
    
      object products {
        trait Item {
          val title   = oneString
          val inStock = oneInt
        }
        // ..more namespaces in the `products` partition
      }
    
      // Additional partitions...
    }
    See also

    Manual | Tests: Schema without partitions, Schema with partitions, Bidirectionals

Inherited from AnyRef

Inherited from Any

Ungrouped