Liking cljdoc? Tell your friends :D

ribelo.doxa


*atom-fn*clj/s


*empty-map*clj/s


*id-sufixes*clj/s


-->cache-kwclj/s

(-->cache-kw query id env)

-datoms-match-datom?clj/s

(-datoms-match-datom? txs-datoms datom)

-datoms-match-query?clj/s

(-datoms-match-query? txs-datoms pq)

-datoms-match-where?clj/s

(-datoms-match-where? txs-datoms datoms)

-edits->datomsclj/s

(-edits->datoms edits)

-ident?clj/s

(-ident? x)

-idents?clj/s

(-idents? xs)

-keyclj/smacro

(-key m)

-match-two-datomsclj/s

(-match-two-datoms d1 d2)

-pullclj/s

(-pull db query)
(-pull db query parent)
(-pull db query parent env)

-qclj/smacro

(-q {:keys [find first? mapcat? pull keys limit xf] :as pq} db)

-submit-commitclj/s

(-submit-commit db tx)

apply transactions to db.

apply transactions to db.
raw docstring

-valclj/smacro

(-val m)

-valid-query?clj/s

(-valid-query? pq)

BaseCachecljs


build-args-mapclj/s

(build-args-map {:keys [in args] :as pq})

build-meander-queryclj/s

(build-meander-query m)

collect-argsclj/s

(collect-args xs)

commitclj/s

(commit db txs)
(commit db txs tx-meta)

apply transactions to db. txs can be either a single transaction or a vector of transactions. returns a modified db. transaction report is stored in the db metadata.

usage: [:dx/put|delete|conj|update|match [table eid] ?m | (?k ?v)]

put: entire map|s with entity id [:dx/put {:person/id :ivan :name "ivan" :age 30}] [:dx/put [{:person/id :ivan :name "ivan" :age 30} ...]]

entire map, without entity id
[:dx/put [:person/id :ivan] {:name "ivan" :age 30}]

ident|s
[:dx/put [:person/id :ivan] :friend [:person/id :petr]]
[:dx/put [:person/id :ivan] :friend [[:person/id :petr] ...]]

reference map|s
[:dx/put [:person/id :ivan] :friend {:person/id :petr :name "petr"}]
[:dx/put [:person/id :ivan] :friend [{:person/id :petr :name "petr"} ...]]

key value
[:dx/put [:person/id :ivan] :age 12]

delete: ident [:dx/delete [:person/id :ivan]]

entity|s
[:dx/delete {:person/id :ivan ...}]
[:dx/delete [{:person/id :ivan ...} ...]]

key
[:dx/delete [:person/id :ivan] :age]

value - like disj
[:dx/delete [:person/id :ivan] :aka "tupen"]

conj: value [:dx/conj [:person/id :ivan] :aka "tupen"]

ident|s
[:dx/conj [:person/id :ivan] :friend [:person/id :petr]]
[:dx/conj [:person/id :ivan] :friend [[:person/id :petr] ...]]

entity|s
[:dx/conj [:person/id :ivan] :friend {:person/id :petr ...}]
[:dx/conj [:person/id :ivan] :friend [{:person/id :petr ...} ...]]

update: entity [:dx/update [:person/id :ivan] (fn [entity] (f entity)]

key
[:dx/update [:person/id :ivan] :age inc]

match: entity [:dx/match [:person/id :ivan] {:person/id :ivan ...}]

key value
[:dx/match [:person/id :ivan] :age 30]

key fn
[:dx/match [:person/id :ivan] :salary #(> % 10000)]
apply transactions to db. txs can be either a single transaction or a vector of
transactions. returns a modified db. transaction report is stored in the
db metadata.

usage:
[:dx/put|delete|conj|update|match [table eid] ?m | (?k ?v)]

put:
    entire map|s with entity id
    [:dx/put {:person/id :ivan :name "ivan" :age 30}]
    [:dx/put [{:person/id :ivan :name "ivan" :age 30} ...]]

    entire map, without entity id
    [:dx/put [:person/id :ivan] {:name "ivan" :age 30}]

    ident|s
    [:dx/put [:person/id :ivan] :friend [:person/id :petr]]
    [:dx/put [:person/id :ivan] :friend [[:person/id :petr] ...]]

    reference map|s
    [:dx/put [:person/id :ivan] :friend {:person/id :petr :name "petr"}]
    [:dx/put [:person/id :ivan] :friend [{:person/id :petr :name "petr"} ...]]

    key value
    [:dx/put [:person/id :ivan] :age 12]

delete:
    ident
    [:dx/delete [:person/id :ivan]]

    entity|s
    [:dx/delete {:person/id :ivan ...}]
    [:dx/delete [{:person/id :ivan ...} ...]]

    key
    [:dx/delete [:person/id :ivan] :age]

    value - like disj
    [:dx/delete [:person/id :ivan] :aka "tupen"]

conj:
    value
    [:dx/conj [:person/id :ivan] :aka "tupen"]

    ident|s
    [:dx/conj [:person/id :ivan] :friend [:person/id :petr]]
    [:dx/conj [:person/id :ivan] :friend [[:person/id :petr] ...]]

    entity|s
    [:dx/conj [:person/id :ivan] :friend {:person/id :petr ...}]
    [:dx/conj [:person/id :ivan] :friend [{:person/id :petr ...} ...]]

update:
    entity
    [:dx/update [:person/id :ivan] (fn [entity] (f entity)]

    key
    [:dx/update [:person/id :ivan] :age inc]

match:
    entity
    [:dx/match [:person/id :ivan] {:person/id :ivan ...}]

    key value
    [:dx/match [:person/id :ivan] :age 30]

    key fn
    [:dx/match [:person/id :ivan] :salary #(> % 10000)]
raw docstring

commit!clj/s

(commit! db_ txs)
(commit! db_ txs tx-meta)

accepts an atom with db, see commit

accepts an atom with db, see `commit`
raw docstring

comp-someclj/s

(comp-some & fns)

conjvclj/s

returns a vector even if the argument is nil

returns a vector even if the argument is nil
raw docstring

create-dxclj/s

(create-dx)
(create-dx data)
(create-dx data opts)

creates a db, can take a map, which is written to the metadata

creates a db, can take a map, which is written to the metadata
raw docstring

datalog->meanderclj/s

(datalog->meander {:keys [where in args] :as q})

db-withclj/s

(db-with data)
(db-with db data)

delete-cached-results!clj/s

(delete-cached-results! db kw)

denormalizeclj/s

(denormalize data)
(denormalize db data)
(denormalize db data max-level)

turns a flat map into a nested one. to avoid stackoverflow and infinite loop, it takes a maximum nesting level as an additional argument

turns a flat map into a nested one. to avoid stackoverflow and infinite loop,
it takes a maximum nesting level as an additional argument
raw docstring

dxs_clj/s


get-dxclj/s

(get-dx k)

get-dx!clj/s

(get-dx! k)

haulclj/s

(haul db)
(haul db x)
(haul db x max-level)

into-mapclj/s

returns a map even if the argument is nil

returns a map even if the argument is nil
raw docstring

ITransactionsclj/sprotocol

-datoms-sinceclj/s

(-datoms-since _ udt)

-lttclj/s

(-ltt _)

-next-idclj/s

(-next-id _)

-prepend!clj/s

(-prepend! _ tx)

-txsclj/s

(-txs _)

join-rulesclj/s

(join-rules rules)

listen!clj/s

(listen! db_ cb)
(listen! db_ k cb)

listens for changes in the db. each time changes are made via commit, the callback is called with the db. the transaction report is written to the db metadata, and may include, depending on the configuration, the transaction time, the difference between the old and new db, the db hash. calling listen twice with the same k overwrites the previous callback.

listens for changes in the db. each time changes are made via commit, the
callback is called with the db. the transaction report is written to the db
metadata, and may include, depending on the configuration, the transaction
time, the difference between the old and new db, the db hash. calling listen
twice with the same k overwrites the previous callback.
raw docstring

normalizeclj/s

(normalize data)

turns a nested map into a flat collection with references.

turns a nested map into a flat collection with references.
raw docstring

parse-findclj/s

(parse-find args)

parse-queryclj/s

(parse-query q & args)

parse-query-elemclj/s

(parse-query-elem elem args-map)

patchclj/s

(patch db edits)
(patch db edits time)

patch db using ediscript edits

patch db using ediscript edits
raw docstring

patch!clj/s

(patch! db_ edits)
(patch! db_ edits time)

patch db inside atom, see patch

patch db inside atom, see `patch`
raw docstring

pullclj/smacro

(pull db query id)
(pull db query id env)

pull->datalogclj/s

(pull->datalog query ids)

pull-oneclj/s

(pull-one db query)
(pull-one db query id)

qclj/smacro

(q q' db & args)

qsymbol?clj/s

(qsymbol? x)

queryclj

(query args)

reg-dx!clj/s

(reg-dx! id store)

replace-all-argsclj/s

(replace-all-args body args)

(reverse-search db id)
(reverse-search db k id)

rewrite-all-argsclj/s


rewrite-argclj/s

(rewrite-arg arg)

simplify-whereclj/s

(simplify-where where args-map)

TickedCacheEntrycljs


Transactioncljs


Transactionscljs


unlisten!clj/s

(unlisten! db_ k)

remove registered listener

remove registered listener
raw docstring

valid-id?clj/s

(valid-id? id)

with-commitclj/s

(with-commit db txs)

with-dxclj/smacro

(with-dx bindings & body)

with-dx!clj/smacro

(with-dx! bindings & body)

with-time-msclj/smacro

(with-time-ms & body)

macro establishes the execution time of the body and returns a result with attached metadata, with key execution-time in milliseconds

macro establishes the execution time of the body and returns a result with
attached metadata, with key `execution-time` in milliseconds
raw docstring

wrap-or-args-with-letclj/s

(wrap-or-args-with-let xs)

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close