/** * This file is part of the @egodigital/egoose distribution. * Copyright (c) e.GO Digital GmbH, Aachen, Germany (https://www.e-go-digital.com/) * * @egodigital/egoose is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as * published by the Free Software Foundation, version 3. * * @egodigital/egoose is distributed in the hope that it will be useful, but * WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public License * along with this program. If not, see . */ import { CacheBase, SetCacheValueOptions } from './index'; /** * Options for redis cache (client). */ export interface RedisCacheOptions { /** * The custom host. */ host?: string; /** * The custom TCP port. */ port?: number; } /** * A Redis cache (client). */ export declare class RedisCache extends CacheBase { readonly options: RedisCacheOptions; /** * Initializes a new instance of that class. * * @param {RedisCacheOptions} options The options. */ constructor(options: RedisCacheOptions); private createClient; /** * Creates a new instance from environment variable. * * @return {RedisCache} The new instance. */ static fromEnvironment(): RedisCache; /** @inheritdoc */ protected getInner(key: any, defaultValue: any): Promise; /** @inheritdoc */ protected setInner(key: any, value: any, opts: SetCacheValueOptions): Promise; private withConnection; }