UNPKG

1.61 kBSource Map (JSON)View Raw
1{"version":3,"sources":["../../src/cache/QueryResultCache.ts"],"names":[],"mappings":"","file":"QueryResultCache.js","sourcesContent":["import {QueryResultCacheOptions} from \"./QueryResultCacheOptions\";\nimport {QueryRunner} from \"../query-runner/QueryRunner\";\n\n/**\n * Implementations of this interface provide different strategies to cache query builder results.\n */\nexport interface QueryResultCache {\n\n /**\n * Creates a connection with given cache provider.\n */\n connect(): Promise<void>;\n\n /**\n * Closes a connection with given cache provider.\n */\n disconnect(): Promise<void>;\n\n /**\n * Performs operations needs to be created during schema synchronization.\n */\n synchronize(queryRunner?: QueryRunner): Promise<void>;\n\n /**\n * Caches given query result.\n */\n getFromCache(options: QueryResultCacheOptions, queryRunner?: QueryRunner): Promise<QueryResultCacheOptions|undefined>;\n\n /**\n * Stores given query result in the cache.\n */\n storeInCache(options: QueryResultCacheOptions, savedCache: QueryResultCacheOptions|undefined, queryRunner?: QueryRunner): Promise<void>;\n\n /**\n * Checks if cache is expired or not.\n */\n isExpired(savedCache: QueryResultCacheOptions): boolean;\n\n /**\n * Clears everything stored in the cache.\n */\n clear(queryRunner?: QueryRunner): Promise<void>;\n\n /**\n * Removes all cached results by given identifiers from cache.\n */\n remove(identifiers: string[], queryRunner?: QueryRunner): Promise<void>;\n\n}"],"sourceRoot":".."}
\No newline at end of file