-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.d.ts
More file actions
39 lines (33 loc) · 1.2 KB
/
index.d.ts
File metadata and controls
39 lines (33 loc) · 1.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
import Cache from "./cache"
import HashCache from "./hashCache"
import {Redis as IoRedis} from "ioredis"
import SortedSetCache from "./sortedSetCache"
declare class Redis {
/**
* The Cache class for basic caching functions.
* @returns {typeof Cache} The Cache class.
*/
static get Cache(): typeof Cache
/**
* The HashCache class for caching functions related to hashes.
* @returns {typeof HashCache} The HashCache class.
*/
static get HashCache(): typeof HashCache
/**
* The SortedSet class for caching functions related to sorted sets.
* @returns {typeof SortedSetCache} The SortedSetCache class.
*/
static get SortedSetCache(): typeof SortedSetCache
/**
* Gets a redis client. Intended to be called by services that only need one client.
* @returns {PromiseLike<IoRedis>} A promise that resolves with the client.
*/
static getClient(): PromiseLike<IoRedis>
/**
* Setup the connection to Redis.
* @param {{host: string, port: number, password: string}} options The connection options.
* @returns {void}
*/
static setup(options: {host: string, port: number, password: string}): void
}
export = Redis