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
raw docstring

add-identclj

(add-ident q schema ident arg)

Add a where clause for an ident

Add a where clause for an ident
raw 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
raw docstring

build-queryclj

(build-query env entity fields)

Build a base query preparing joins when needed

Build a base query preparing joins when needed
raw 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
raw 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
raw 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
raw docstring

find-listenersclj

(find-listeners env mutation)

Fetch listeners

Fetch listeners
raw docstring

find-mutationclj

(find-mutation env mutation)

Fetch mutation description

Fetch mutation description
raw docstring

merge-compounds-fnclj

(merge-compounds-fn compounds)

Merge compounds into record

Merge compounds into record
raw 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.
raw 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
raw 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
raw 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
raw 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
raw docstring

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
raw docstring

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
raw docstring

qualify-resultclj

(qualify-result m)

Qualify a result with the appropriate namespace

Qualify a result with the appropriate namespace
raw docstring

queryclj

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

Look up entities.

Look up entities.
raw docstring

recompose-relationsclj

(recompose-relations 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.

raw 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.
raw 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 
raw docstring

table-fieldclj

(table-field table field)

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
raw 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.
raw docstring

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

× close