import Big from "big.js"; import { Channel, ChannelEventSource } from "../../internal"; import { PerpetualProtocolConnected } from "../PerpetualProtocol"; import { Liquidity } from "./Liquidity"; export interface UpdatedDataReturn { openLiquiditiesFromMarkets: { [marketBaseAddress: string]: Liquidity[]; }; totalPendingFees: { [marketBaseAddress: string]: Big; }; } declare type LiquiditiesEventName = "updateError" | "updated" | "updatedLiquidityDataAll"; declare class Liquidities extends Channel { private readonly _perp; private _cache; private readonly _fetchAndEmitUpdated; constructor(_perp: PerpetualProtocolConnected); private _compareUpdatedData; protected _getEventSourceMap(): { updated: ChannelEventSource; updatedLiquidityDataAll: ChannelEventSource; }; private _fetchUpdateData; getTotalLiquidities({ cache }?: { cache?: boolean | undefined; }): Promise<{ [marketBaseAddress: string]: Big; }>; getTotalLiquidityByMarket(baseAddress: string, { cache }?: { cache?: boolean | undefined; }): Promise; getTotalPendingFees({ cache }?: { cache?: boolean | undefined; }): Promise<{ [marketBaseAddress: string]: Big; }>; getTotalPendingFeeByMarket(baseAddress: string, { cache }?: { cache?: boolean | undefined; }): Promise; getOpenLiquiditiesFromMarkets({ cache }?: { cache?: boolean | undefined; }): Promise<{ [marketBaseAddress: string]: Liquidity[]; }>; getOpenLiquiditiesByMarket(baseAddress: string, { cache }?: { cache?: boolean | undefined; }): Promise; private _fetch; protected getLiquidityDataAll(): Promise; } export { Liquidities }; export interface LiquidityData { totalPendingFee: Big; totalLiquidityValue: Big; openOrderIds: number[]; openLiquidities: Liquidity[]; marketPrice: Big; } export declare type LiquidityDataAll = Record;