2014-04-22 18:28:10 -05:00
|
|
|
package main
|
|
|
|
|
|
|
|
import (
|
|
|
|
"github.com/conformal/btcwire"
|
|
|
|
)
|
|
|
|
|
|
|
|
type Client struct {
|
|
|
|
btcnet btcwire.BitcoinNet // Bitcoin Network
|
|
|
|
pver uint32 // Protocl Version
|
|
|
|
userAgent string // User Agent
|
|
|
|
}
|
|
|
|
|
2014-04-23 18:03:34 -05:00
|
|
|
func NewClient(userAgent string) *Client {
|
2014-04-22 18:28:10 -05:00
|
|
|
return &Client{
|
|
|
|
btcnet: btcwire.MainNet,
|
|
|
|
pver: btcwire.ProtocolVersion,
|
|
|
|
userAgent: userAgent,
|
|
|
|
}
|
|
|
|
}
|