import { IEscrowSwap, IEscrowSwapInit } from "./IEscrowSwap"; import { ChainType, SignatureData, SwapData } from "@atomiqlabs/base"; import { SCToken, TokenAmount } from "../../Tokens"; import { IEscrowSwapWrapper } from "./IEscrowSwapWrapper"; export type IEscrowSelfInitSwapInit = IEscrowSwapInit & { feeRate: any; signatureData: SignatureData; }; export declare function isIEscrowSelfInitSwapInit(obj: any): obj is IEscrowSelfInitSwapInit; export declare abstract class IEscrowSelfInitSwap extends IEscrowSwap { signatureData?: SignatureData; feeRate?: any; protected constructor(wrapper: IEscrowSwapWrapper>, obj: any); protected constructor(wrapper: IEscrowSwapWrapper>, swapInit: IEscrowSelfInitSwapInit); /** * Periodically checks for init signature's expiry * * @param intervalSeconds How often to check (in seconds), default to 5s * @param abortSignal * @protected */ protected watchdogWaitTillSignatureExpiry(intervalSeconds?: number, abortSignal?: AbortSignal): Promise; /** * Get the estimated smart chain fee of the commit transaction */ protected getCommitFee(): Promise; /** * Returns the transaction fee paid on the smart chain */ getSmartChainNetworkFee(): Promise>>; /** * Checks if the initiator/sender has enough balance to cover the transaction fee for processing the swap */ abstract hasEnoughForTxFees(): Promise<{ enoughBalance: boolean; balance: TokenAmount; required: TokenAmount; }>; abstract txsCommit(skipChecks?: boolean): Promise; abstract commit(_signer: T["Signer"] | T["NativeSigner"], abortSignal?: AbortSignal, skipChecks?: boolean, onBeforeTxSent?: (txId: string) => void): Promise; /** * Checks if the swap's quote is expired for good (i.e. the swap strictly cannot be committed on-chain anymore) */ _verifyQuoteDefinitelyExpired(): Promise; /** * Checks if the swap's quote is still valid */ verifyQuoteValid(): Promise; serialize(): any; }