Documentation ¶
Index ¶
- type BitBoxBase
- func (base *BitBoxBase) BlockInfo() string
- func (base *BitBoxBase) Close()
- func (base *BitBoxBase) ConnectElectrum() error
- func (base *BitBoxBase) GetRegisterTime() time.Time
- func (base *BitBoxBase) GetUpdaterInstance() *updater.Updater
- func (base *BitBoxBase) Identifier() string
- func (base *BitBoxBase) Init(testing bool)
- type Interface
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BitBoxBase ¶
type BitBoxBase struct {
// contains filtered or unexported fields
}
BitBoxBase provides the dictated bitboxbase api to communicate with the base
func NewBitBoxBase ¶
NewBitBoxBase creates a new bitboxBase instance
func (*BitBoxBase) BlockInfo ¶
func (base *BitBoxBase) BlockInfo() string
BlockInfo returns the received blockinfo packet from the updater
func (*BitBoxBase) Close ¶
func (base *BitBoxBase) Close()
Close implements a method to unset the bitboxBase
func (*BitBoxBase) ConnectElectrum ¶
func (base *BitBoxBase) ConnectElectrum() error
ConnectElectrum connects to the electrs server on the base and configures the backend accordingly
func (*BitBoxBase) GetRegisterTime ¶
func (base *BitBoxBase) GetRegisterTime() time.Time
GetRegisterTime implements a getter for the timestamp of when the bitboxBase was registered
func (*BitBoxBase) GetUpdaterInstance ¶
func (base *BitBoxBase) GetUpdaterInstance() *updater.Updater
GetUpdaterInstance return ths current instance of the updater
func (*BitBoxBase) Identifier ¶
func (base *BitBoxBase) Identifier() string
Identifier implements a getter for the bitboxBase ID
func (*BitBoxBase) Init ¶
func (base *BitBoxBase) Init(testing bool)
Init initializes the bitboxBase
type Interface ¶
type Interface interface { Init(testing bool) // Identifier returns the bitboxBaseID. Identifier() string // GetUpdater returns the updater so we can listen to its events. GetUpdaterInstance() *updater.Updater // Close tells the bitboxbase to close all connections. Close() //GetRegisterTime implements a getter for the timestamp of when the bitboxBase was registered GetRegisterTime() time.Time // BlockInfo returns some blockchain information. BlockInfo() string // ConnectElectrum connects to the electrs server on the base and configures the backend accordingly ConnectElectrum() error }
Interface represents bitbox base.
Directories ¶
Path | Synopsis |
---|---|
Package mdns manages detects and/or registers new bitbox bases.
|
Package mdns manages detects and/or registers new bitbox bases. |
Package updater manages the connection with the bitboxbase, establishing a websocket listener and sending events when receiving packets.
|
Package updater manages the connection with the bitboxbase, establishing a websocket listener and sending events when receiving packets. |
Click to show internal directories.
Click to hide internal directories.