workflo.entitydb.util.operations

add-entities

(add-entities db db-config entity-name entities)(add-entities db db-config entity-name entities merge-fn)

add-entity

(add-entity db db-config entity-name entity)(add-entity db db-config entity-name entity merge-fn)

Adds the given entity to the db, or updates the existing instance if the entity already exists in the db.

default-merge

(default-merge entity-1 entity-2)

remove-entities

(remove-entities db db-config entity-name entities)

Removes all given entities from the db.

remove-entity

(remove-entity db db-config entity-name entity)

Removes the given entity from the db.

remove-entity-by-ref

(remove-entity-by-ref db db-config ref)

Removes the entity from the db that corresponds to the given ref. Note: This is a slow operation, as the ref lacks type information and thus this function has to check all entity maps to find the corresponding entity.

update-entity

(update-entity db db-config entity-name entity)(update-entity db db-config entity-name entity merge-fn)