Liking cljdoc? Tell your friends :D

seql.core

A way to interact with stored entities

A way to interact with stored entities
raw docstring

add-conditionclj

(add-condition schema q [condition & args])

If conditions are provided, add them to the query

If conditions are provided, add them to the query
sourceraw docstring

add-identclj

(add-ident q entity-name ident arg)

Add a where clause for an ident

Add a where clause for an ident
sourceraw docstring

add-listener!clj

(add-listener! env mutation handler)
(add-listener! env mutation key handler)

Given an environment, add a mutation handler. The handlers is bound by key, if specified, otherwise the key will default to the mutation key. Yields an updated environment

Given an environment, add a mutation handler.
The handlers is bound by `key`, if specified, otherwise the `key` will
default to the mutation key. Yields an updated environment
sourceraw docstring

build-queryclj

(build-query env entity fields)

Build a base query preparing joins when needed

Build a base query preparing joins when needed
sourceraw docstring

compound-extra-fieldsclj

(compound-extra-fields compounds fields)

Figure out which fields aren't needed once compounds have been processed on a record

Figure out which fields aren't needed once compounds have been
processed on a record
sourceraw docstring

entity-schemaclj

(entity-schema {:keys [schema]} entity)

Look up entity in schema. Takes a schema and an entity. The entity argument can take be of two different shapes: it can be a keyword that will match the namespace of the entity in question or a coll of namespaced keyword (ident name) and arguments

Look up entity in schema. Takes a schema and an entity. The entity
argument can take be of two different shapes: it can be a keyword
that will match the namespace of the entity in question or a coll of
namespaced keyword (ident name) and arguments
sourceraw docstring

extract-identclj

(extract-ident entity result)

When a query is targetting an ident, extract the first result

When a query is targetting an ident,
extract the first result
sourceraw docstring

find-listenersclj

(find-listeners env mutation)

Fetch listeners

Fetch listeners
sourceraw docstring

find-mutationclj

(find-mutation env mutation)

Fetch mutation description

Fetch mutation description
sourceraw docstring

merge-compounds-fnclj

(merge-compounds-fn compounds)

Merge compounds into record

Merge compounds into record
sourceraw docstring

mutate!clj

(mutate! env mutation params)
(mutate! env mutation params metadata)

Perform a mutation. Since mutations are spec'd, parameters are expected to conform it.

Perform a mutation. Since mutations are spec'd, parameters are
expected to conform it.
sourceraw docstring

prepare-fieldclj

(prepare-field schema field value)

Conditionally apply field transform on field id if schema defines any

Conditionally apply field transform on field id if schema defines
any
sourceraw docstring

process-compounds-fnclj

(process-compounds-fn schema {:seql.core/keys [fields]})

Yield a schema-specific function to process compounds on the fly

Yield a schema-specific function to process compounds on the fly
sourceraw docstring

process-fieldclj

(process-field schema {:keys [relations compounds fields entity]})

Add necessary stanzas to realize field targeting with SQL

Add necessary stanzas to realize field targeting with SQL
sourceraw docstring

process-joincljmultimethod

Process join by relation type. Takes a base query, a map with :entity and :table keys and a map of options to build the relation

Process join by relation type. Takes a base query, a map with
`:entity` and `:table` keys and a map of options to build the
relation
sourceraw docstring

process-read-transformsclj

(process-read-transforms m)
source

process-transforms-fnclj

(process-transforms-fn schema type)

Yield a function which processes records and applies predefined transforms

Yield a function which processes records and applies predefined
transforms
sourceraw docstring

process-write-transformsclj

(process-write-transforms m)
source

qualify-keyclj

(qualify-key k)

Given the enforced terminology at query time, yield back a qualified keyword

Given the enforced terminology at query time,
yield back a qualified keyword
sourceraw docstring

qualify-resultclj

(qualify-result m)

Qualify a result with the appropriate namespace

Qualify a result with the appropriate namespace
sourceraw docstring

queryclj

(query env entity)
(query env entity fields)
(query env entity fields conditions)

Look up entities.

Look up entities.
sourceraw docstring

recompose-relationsclj

(recompose-relations schema fields records)

The join query perfomed by query returns a flat list of entries, potentially unsorted (this is database implementation specific) recompose a tree of entities as specified in fields.

The join query perfomed by `query` returns a flat list of entries,
potentially unsorted (this is database implementation specific)
recompose a tree of entities as specified in fields.
sourceraw docstring

relation-fieldsclj

(relation-fields entity-ns row)

Builds a map of <entity> -> #{<relation fields> ...}

Builds a map of <entity> -> #{<relation fields> ...}
sourceraw docstring

remove-empty-relationsclj

(remove-empty-relations entity)

remove cols that are all nils for an entity relation

remove cols that are all nils for an entity relation
sourceraw docstring

remove-listener!clj

(remove-listener! env mutation)
(remove-listener! env mutation key)

Given an environment, remove a mutation handler by key if specified, otherwise it will remove a handler that match the mutation key. Yields an updated environment.

Given an environment, remove a mutation handler by `key` if
specified, otherwise it will remove a handler that match the
mutation `key`. Yields an updated environment.
sourceraw docstring

sql-queryclj

(sql-query env entity fields conditions)

Build a SQL query for the pull-syntax expressed. This is an incremental data-based creation of a

Build a SQL query for the pull-syntax expressed. This is an incremental
data-based creation of a 
sourceraw docstring

success-result?clj

(success-result? result)
source

table-fieldclj

(table-field table field)
source

transform-for-joinclj

(transform-for-join k)

Takes a namespace keyword and returns an identifier in valid SQL format

Takes a namespace keyword and returns an identifier in valid SQL
format
sourceraw docstring

transform-outclj

(transform-out k)

Takes a namespaced keyword and prepare name transforms. Returns a tuple of database name to aliased name.

Takes a namespaced keyword and prepare name transforms.
Returns a tuple of database name to aliased name.
sourceraw docstring

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

× close