Page Contents

Home > @loopback/repository > KeyValueRepository

KeyValueRepository interface

Key/Value operations for connector implementations

Signature:

export interface KeyValueRepository<T extends Model> extends Repository<T> 

Extends: Repository<T>

Methods

Method Description
delete(key, options) Delete an entry by key
deleteAll(options) Delete all entries
expire(key, ttl, options) Set up ttl for an entry by key
get(key, options) Get an entry by key
keys(filter, options)? (Optional) Get an Iterator for matching keys
set(key, value, options) Set an entry with key/value
ttl(key, options)? (Optional) Get ttl for an entry by key