Created
May 13, 2022 20:58
-
-
Save lucasraziel/0827576a7db1aae23a26a7c164551a1e to your computer and use it in GitHub Desktop.
CacheTemplate.ts final Usando NPM Package para criar uma Arquitetura Limpa - Parte 2
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Data from '../dto/data'; | |
import SaveOptions from '../dto/saveOptions'; | |
export default interface ICacheProvider { | |
save(value: Data, prefix: string, options?: SaveOptions): Promise<void>; | |
invalidate(key: string, prefix: string): Promise<void>; | |
recover<T = unknown>(key: string, prefix: string): Promise<T | null>; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment