import LRU from 'lru-cache'; import BigNumber from 'bignumber.js'; import RPCClient from './RPCClient'; import { ICurrency } from './interfaces'; import { Account, Block, Transaction, Transactions, IEndpointsStatus } from './types'; import { TransactionStatus } from './enums'; import { ICurrencyConfig, ISignedRawTransaction, ISubmittedTransaction } from './interfaces'; import AccountHdWallet from './types/AccountHdWallet'; export interface IParamsHDWallet { seed: string; accountIndex: string; path: string; } export declare abstract class BaseGateway { protected _cacheBlock: LRU; protected _cacheTxByHash: LRU; protected _rpcClient: RPCClient; protected readonly _currency: ICurrency; protected constructor(currency: ICurrency); getCurrency(): ICurrency; getCurrencyConfig(): ICurrencyConfig; loadCurrencyConfig(): void; abstract createAccountAsync(): Promise; createAccountHdWalletAsync(params: IParamsHDWallet): Promise; generatePrivateKeyHdWalletAsync(params: IParamsHDWallet): Promise; generateSeed(): string; abstract getAccountFromPrivateKey(privateKey: string): Promise; isValidAddressAsync(address: string): Promise; isNeedTagAsync(address: string): Promise; getNetworkStatus(): Promise; normalizeAddress(address: string): string; getOneTransaction(txid: string): Promise; getParallelNetworkRequestLimit(): number; getTransactionsByIds(txids: string[]): Promise; getOneBlock(blockHash: string | number): Promise; getMultiBlocksTransactions(fromBlockNumber: number, toBlockNumber: number): Promise; getBlockTransactions(blockNumber: string | number): Promise; estimateFee(options: { isConsolidate: boolean; useLowerNetworkFee?: boolean; totalInputs?: number; recentWithdrawalFee?: number; }): Promise; abstract getBlockCount(): Promise; abstract getAddressBalance(address: string): Promise; abstract getTransactionStatus(txid: string): Promise; abstract signRawTransaction(unsignedRaw: string, secret: string | string[]): Promise; abstract sendRawTransaction(signedRawTx: string): Promise; abstract getAverageSeedingFee(): Promise; protected abstract _getOneBlock(blockHash: string | number): Promise; protected abstract _getOneTransaction(txid: string): Promise; protected _getCacheOptions(): { max: number; maxAge: number; }; } export default BaseGateway;