UNPKG

lightningdevkit

Version:
22 lines (21 loc) 1.02 kB
import { Logger } from '../structs/Logger.mjs'; import { CoinSelectionSource } from '../structs/CoinSelectionSource.mjs'; import { WalletSource } from '../structs/WalletSource.mjs'; import { CommonBase } from './CommonBase.mjs'; /** * A wrapper over [`WalletSource`] that implements [`CoinSelection`] by preferring UTXOs that would * avoid conflicting double spends. If not enough UTXOs are available to do so, conflicting double * spends may happen. */ export declare class Wallet extends CommonBase { /** * Returns a new instance backed by the given [`WalletSource`] that serves as an implementation * of [`CoinSelectionSource`]. */ static constructor_new(source: WalletSource, logger: Logger): Wallet; /** * Constructs a new CoinSelectionSource which calls the relevant methods on this_arg. * This copies the `inner` pointer in this_arg and thus the returned CoinSelectionSource must be freed before this_arg is */ as_CoinSelectionSource(): CoinSelectionSource; }