cnct+lnwl+hswc: use lntypes.Preimage for witness beacon
This commit is contained in:
16 files changed
+126
-114
No files matched your search
@@ -9,6 +9,7 @@ import (
|
||||
"github.com/btcsuite/btcd/chaincfg/chainhash"
|
||||
"github.com/btcsuite/btcd/wire"
|
||||
"github.com/btcsuite/btcutil"
|
||||
"github.com/lightningnetwork/lnd/lntypes"
|
||||
)
|
||||
|
||||
// AddressType is an enum-like type which denotes the possible address types
|
||||
@@ -272,15 +273,12 @@ type PreimageCache interface {
|
||||
// LookupPreimage attempts to look up a preimage according to its hash.
|
||||
// If found, the preimage is returned along with true for the second
|
||||
// argument. Otherwise, it'll return false.
|
||||
LookupPreimage(hash []byte) ([]byte, bool)
|
||||
LookupPreimage(hash lntypes.Hash) (lntypes.Preimage, bool)
|
||||
|
||||
// AddPreimages adds a batch of newly discovered preimages to the global
|
||||
// cache, and also signals any subscribers of the newly discovered
|
||||
// witness.
|
||||
//
|
||||
// NOTE: The backing slice of MUST NOT be modified, otherwise the
|
||||
// subscribers may be notified of the incorrect preimages.
|
||||
AddPreimages(preimages ...[]byte) error
|
||||
AddPreimages(preimages ...lntypes.Preimage) error
|
||||
}
|
||||
|
||||
// WalletDriver represents a "driver" for a particular concrete
|
||||
|
||||
Reference in new issue
Block a user