Versions in this module Expand all Collapse all v0 v0.12.2 Mar 18, 2021 Changes in this version + var ErrRemoteCanceled = errors.New(...) + var ErrUserCanceled = errors.New("user canceled funding") + func DisableLog() + func UseLogger(logger btclog.Logger) + type Assembler interface + ProvisionChannel func(*Request) (Intent, error) + type CannedAssembler struct + func NewCannedAssembler(thawHeight uint32, chanPoint wire.OutPoint, fundingAmt vclutil.Amount, ...) *CannedAssembler + func (c *CannedAssembler) ProvisionChannel(req *Request) (Intent, error) + type Coin struct + func CoinSelect(feeRate chainfee.SatPerKWeight, amt vclutil.Amount, coins []Coin) ([]Coin, vclutil.Amount, error) + func CoinSelectSubtractFees(feeRate chainfee.SatPerKWeight, amt, dustLimit vclutil.Amount, coins []Coin) ([]Coin, vclutil.Amount, vclutil.Amount, error) + type CoinSelectionLocker interface + WithCoinSelectLock func(func() error) error + type CoinSource interface + CoinFromOutPoint func(wire.OutPoint) (*Coin, error) + ListCoins func(minConfs, maxConfs int32) ([]Coin, error) + type ConditionalPublishAssembler interface + ShouldPublishFundingTx func() bool + type ErrInsufficientFunds struct + func (e *ErrInsufficientFunds) Error() string + type FullIntent struct + ChangeOutputs []*wire.TxOut + InputCoins []Coin + func (f *FullIntent) BindKeys(localKey *keychain.KeyDescriptor, remoteKey *btcec.PublicKey) + func (f *FullIntent) Cancel() + func (f *FullIntent) CompileFundingTx(extraInputs []*wire.TxIn, extraOutputs []*wire.TxOut) (*wire.MsgTx, error) + func (f *FullIntent) Inputs() []wire.OutPoint + func (f *FullIntent) Outputs() []*wire.TxOut + type FundingKeys struct + LocalKey *keychain.KeyDescriptor + RemoteKey *btcec.PublicKey + type FundingTxAssembler interface + FundingTxAvailable func() + type Intent interface + Cancel func() + ChanPoint func() (*wire.OutPoint, error) + FundingOutput func() ([]byte, *wire.TxOut, error) + Inputs func() []wire.OutPoint + LocalFundingAmt func() vclutil.Amount + Outputs func() []*wire.TxOut + RemoteFundingAmt func() vclutil.Amount + type OutpointLocker interface + LockOutpoint func(o wire.OutPoint) + UnlockOutpoint func(o wire.OutPoint) + type PsbtAssembler struct + func NewPsbtAssembler(fundingAmt vclutil.Amount, basePsbt *psbt.Packet, netParams *chaincfg.Params, ...) *PsbtAssembler + func (p *PsbtAssembler) ProvisionChannel(req *Request) (Intent, error) + func (p *PsbtAssembler) ShouldPublishFundingTx() bool + type PsbtIntent struct + BasePsbt *psbt.Packet + FinalTX *wire.MsgTx + PendingPsbt *psbt.Packet + PsbtReady chan error + State PsbtState + func (i *PsbtIntent) BindKeys(localKey *keychain.KeyDescriptor, remoteKey *btcec.PublicKey) + func (i *PsbtIntent) Cancel() + func (i *PsbtIntent) CompileFundingTx() (*wire.MsgTx, error) + func (i *PsbtIntent) Finalize(packet *psbt.Packet) error + func (i *PsbtIntent) FinalizeRawTX(rawTx *wire.MsgTx) error + func (i *PsbtIntent) FundingParams() (vclutil.Address, int64, *psbt.Packet, error) + func (i *PsbtIntent) Inputs() []wire.OutPoint + func (i *PsbtIntent) Outputs() []*wire.TxOut + func (i *PsbtIntent) RemoteCanceled() + func (i *PsbtIntent) Verify(packet *psbt.Packet) error + type PsbtState uint8 + const PsbtFinalized + const PsbtFundingTxCompiled + const PsbtInitiatorCanceled + const PsbtOutputKnown + const PsbtResponderCanceled + const PsbtShimRegistered + const PsbtVerified + func (s PsbtState) String() string + type Request struct + ChangeAddr func() (vclutil.Address, error) + FeeRate chainfee.SatPerKWeight + LocalAmt vclutil.Amount + MinConfs int32 + RemoteAmt vclutil.Amount + SubtractFees bool + type ShimIntent struct + func (s *ShimIntent) Cancel() + func (s *ShimIntent) ChanPoint() (*wire.OutPoint, error) + func (s *ShimIntent) FundingOutput() ([]byte, *wire.TxOut, error) + func (s *ShimIntent) Inputs() []wire.OutPoint + func (s *ShimIntent) LocalFundingAmt() vclutil.Amount + func (s *ShimIntent) MultiSigKeys() (*FundingKeys, error) + func (s *ShimIntent) Outputs() []*wire.TxOut + func (s *ShimIntent) RemoteFundingAmt() vclutil.Amount + func (s *ShimIntent) ThawHeight() uint32 + type WalletAssembler struct + func NewWalletAssembler(cfg WalletConfig) *WalletAssembler + func (w *WalletAssembler) FundingTxAvailable() + func (w *WalletAssembler) ProvisionChannel(r *Request) (Intent, error) + type WalletConfig struct + CoinLocker OutpointLocker + CoinSelectLocker CoinSelectionLocker + CoinSource CoinSource + DustLimit vclutil.Amount + Signer input.Signer