Exposes a concise, function-based Clojure DSL for declaring Datomic schema transactions. See the doc of #'attr for more details.
Exposes a concise, function-based Clojure DSL for declaring Datomic schema transactions. See the doc of #'attr for more details.
(attr ident & clauses)
Creates a attribute named :ident
from the given DSL clauses.
A clause can be:
The allowed keywords and their meaning are:
The clauses are applied in order, so a clause on the right may overrule a clause on its left.
Creates a attribute named `:ident` from the given DSL clauses. A clause can be: * a map, which will be merged into the map for the attribute (example: {:db/index true, :db/fulltext false}) * a string, which will be added to the attribute as its :db/doc * a keyword, which will be interpreted specially. The allowed keywords and their meaning are: * :string / :db.type/string / :boolean / :db.type/boolean / ... : sets the :db/valueType of the attribute. See http://docs.datomic.com/schema.html for the full list of value types. * :one / db.cardinality/one: sets :db/cardinality to :db.cardinality/one (which is the default if unspecified) * :many / db.cardinality/many: sets :db/cardinality to :db.cardinality/many * :identity / :db.unique/identity: set :db/unique to :db.unique/identity * :value / :db.unique/value: set :db/unique to :db.unique/value * :component: sets :db/isComponent to true * :index: sets :db/index to true * :fulltext: sets :db/fulltext to true * :noHistory: sets :db/noHistory to true The clauses are applied in order, so a clause on the right may overrule a clause on its left.
(db-clj-fn ident params code)
(db-clj-fn ident doc params code)
Shorthand for making a Clojure database function. Will require datomic.api with alias d/
Shorthand for making a Clojure database function. Will require datomic.api with alias d/
(db-fn ident config)
(db-fn ident doc config)
Shorthand for Datomic database functions.
config
is what should be passed to
Shorthand for Datomic database functions. `config` is what should be passed to
(named ident & clauses)
Shorthand for named entities (defined with a keyword, e.g enums)
Shorthand for named entities (defined with a keyword, e.g enums)
(part ident & clauses)
Shorhand for creating partitions
Shorhand for creating partitions
(to-many ident & clauses)
Shorthand for a ref-typed, cardinality-many attribute
Shorthand for a ref-typed, cardinality-many attribute
(to-one ident & clauses)
Shorthand for a ref-typed, cardinality-one attribute
Shorthand for a ref-typed, cardinality-one attribute
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close