*add dhtCache to RPCCache
This commit is contained in:
parent
b139bba69a
commit
632bd19635
|
@ -11,6 +11,7 @@
|
||||||
"typescript": "^4.9.4"
|
"typescript": "^4.9.4"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
"@lumeweb/dht-cache": "https://git.lumeweb.com/LumeWeb/dht-cache.git",
|
||||||
"@types/eventemitter2": "^4.1.0",
|
"@types/eventemitter2": "^4.1.0",
|
||||||
"arg": "^5.0.2",
|
"arg": "^5.0.2",
|
||||||
"eventemitter2": "^6.4.9",
|
"eventemitter2": "^6.4.9",
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
import type EventEmitter from "events";
|
import type EventEmitter from "events";
|
||||||
import type NodeCache from "node-cache";
|
import type NodeCache from "node-cache";
|
||||||
|
import type DHTCache from "@lumeweb/dht-cache";
|
||||||
|
|
||||||
export interface RPCRequest {
|
export interface RPCRequest {
|
||||||
module: string;
|
module: string;
|
||||||
|
@ -57,6 +58,7 @@ export declare class RPCServer extends EventEmitter {
|
||||||
}
|
}
|
||||||
export declare class RPCCache extends EventEmitter {
|
export declare class RPCCache extends EventEmitter {
|
||||||
get data(): NodeCache;
|
get data(): NodeCache;
|
||||||
|
get dhtCache(): DHTCache;
|
||||||
constructor(server: RPCServer);
|
constructor(server: RPCServer);
|
||||||
public signResponse(item: RPCCacheItem): any;
|
public signResponse(item: RPCCacheItem): any;
|
||||||
public verifyResponse(pubkey: Buffer, item: RPCCacheItem): boolean | Buffer;
|
public verifyResponse(pubkey: Buffer, item: RPCCacheItem): boolean | Buffer;
|
||||||
|
|
Loading…
Reference in New Issue