netiam-adapter-sequelize

A sequelize persistence adapter
Get it
npm i -S netiam netiam-adapter-sequelize
Anatomy of a persistence adapter
Every adapter has to export a public interface with the following requirements.
getId(type) {
}
getType(model) {
}
getType(model) {
}
find(type, id, opts) {
}
update(type, id, opts) {
}
remove(type, id) {
}
setAttributes(type, resource, attributes) {
}
getAttributes(type, resource) {
}
getAttributeKeys(type, resource) {
}
setRelationship(type, resource, relationship, resourceIdentifiers) {
}
setRelationships(type, resource, relationships) {
}
getRelationship(type, resource, relationship) {
}
getRelationshipKeys(type, resource) {
}
hasRelationship(type, relationship) {
}
getRelationshipType(type, relationship) {
}
License
MIT License