2015-12-03 03:49:41 +03:00
|
|
|
package wallet
|
|
|
|
|
2015-12-16 23:40:11 +03:00
|
|
|
import (
|
|
|
|
"sync"
|
|
|
|
|
|
|
|
"li.lan/labs/plasma/chainntfs"
|
|
|
|
"li.lan/labs/plasma/revocation"
|
|
|
|
|
|
|
|
"github.com/btcsuite/btcwallet/walletdb"
|
|
|
|
)
|
|
|
|
|
2015-12-03 03:49:41 +03:00
|
|
|
type LightningChannel struct {
|
2015-12-16 23:43:59 +03:00
|
|
|
shachan *revocation.HyperShaChain
|
2015-12-16 23:40:11 +03:00
|
|
|
wallet *LightningWallet
|
|
|
|
|
|
|
|
channelEvents *chainntnfs.ChainNotifier
|
|
|
|
|
|
|
|
sync.RWMutex
|
|
|
|
|
|
|
|
channelNamespace walletdb.Namespace
|
|
|
|
|
|
|
|
// TODO(roasbeef): create and embed 'Service' interface w/ below?
|
|
|
|
started int32
|
|
|
|
|
|
|
|
shutdown int32
|
|
|
|
|
|
|
|
quit chan struct{}
|
|
|
|
wg sync.WaitGroup
|
|
|
|
}
|
|
|
|
|
|
|
|
func newLightningChannel() *LightningChannel {
|
|
|
|
return nil
|
2015-12-03 03:49:41 +03:00
|
|
|
}
|