///
import { EventEmitter } from "events";
import { IRedisOptions, NodeKey, NodeRole } from "./util";
export default class ConnectionPool extends EventEmitter {
private redisOptions;
private nodes;
private specifiedOptions;
constructor(redisOptions: any);
getNodes(role?: NodeRole): any[];
getInstanceByKey(key: NodeKey): any;
getSampleInstance(role: NodeRole): any;
/**
* Find or create a connection to the node
*
* @param {IRedisOptions} node
* @param {boolean} [readOnly=false]
* @returns {*}
* @memberof ConnectionPool
*/
findOrCreate(node: IRedisOptions, readOnly?: boolean): any;
/**
* Remove a node from the pool.
*/
private removeNode;
/**
* Reset the pool with a set of nodes.
* The old node will be removed.
*
* @param {(Array)} nodes
* @memberof ConnectionPool
*/
reset(nodes: IRedisOptions[]): void;
}