(->entity-ref entity)
Returns the ref name for given entity name e.g. :my-cool/entity -> :my-cool/entity-ref
Returns the ref name for given entity name e.g. :my-cool/entity -> :my-cool/entity-ref
(->entity-ref-schema schema)
Will return a simplified malli schema for a given entity Basically wil try to identify a type of primary key field
Will return a simplified malli schema for a given entity Basically wil try to identify a type of primary key field
(->ref-spec-type entity)
(create-entity entity config)
Constructor function for entities
Constructor function for entities
(depends-on? target dependency)
Check if one entity depends on the other as foreign tables in SQL
Check if one entity depends on the other as foreign tables in SQL
Mutable malli registry to hold all defined by user entities + some utility schemas
Mutable malli registry to hold all defined by user entities + some utility schemas
(entity-columns entity)
Return a list of entity fields names (keywords)
Return a list of entity fields names (keywords)
(entity-entries entity)
Return a list of entity fields specs (map-entries)
Return a list of entity fields specs (map-entries)
(entity-key->entity-name entity-key)
(entity-values entity data)
Extract entity columns data. map -> table e.g. {:id 1 :name 'Jack'} -> [1 'Jack']
Extract entity columns data. map -> table e.g. {:id 1 :name 'Jack'} -> [1 'Jack']
Recursive malli schema to parse provided by user entities schemas e.g. [:spec {:table "client"} [:id {:primary-key? true} uuid?] [:name [:string {:max 250}]] [:user {:one-to-many? true} :fx.entity-test/user]]
Recursive malli schema to parse provided by user entities schemas e.g. [:spec {:table "client"} [:id {:primary-key? true} uuid?] [:name [:string {:max 250}]] [:user {:one-to-many? true} :fx.entity-test/user]]
Recursive malli schema to unparse provided by user entities schemas to internal schema representation
Recursive malli schema to unparse provided by user entities schemas to internal schema representation
(entry-schema entry-schema)
Get the simplified definition of the field spec
Get the simplified definition of the field spec
(entry-schema-table entry-schema)
Get table name from field spec
Get table name from field spec
(optional-ref? props)
Check if some reference field is optional
Check if some reference field is optional
(create! _ params)
(delete! _)
(find! _)
(find-all! _)
(update! _)
(prepare-spec spec)
Transform the user defined entity spec to something more understandable for malli. Original specs will cause errors due to cress spec references
Transform the user defined entity spec to something more understandable for malli. Original specs will cause errors due to cress spec references
(primary-key-schema entity)
Get the spec of a field which is marked as primary key
Get the spec of a field which is marked as primary key
(properties schema)
Get the schema properties map if presented
Get the schema properties map if presented
(ref? type)
Check if type is a reference to another entity
Check if type is a reference to another entity
(register-entity! entity schema)
Adds entity and its reference schemas to the global registry
Adds entity and its reference schemas to the global registry
(register-entity-ref! entity schema)
Adds the entity ref schema to the global registry
Adds the entity ref schema to the global registry
(valid-entity? entity data)
Check if data is aligned with entity spec
Check if data is aligned with entity spec
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close