btc-crawl/client.go

20 lines
367 B
Go
Raw Normal View History

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