func (c *Client) GetConnectionCount() (int64, error) {
	return c.GetConnectionCountAsync().Receive()
}
GetConnectionCount returns the number of active connections to other peers.
package rpcclient
import (
	"encoding/json"
	"github.com/stevenroose/go-bitcoin-core-rpc/btcjson"
)
type AddNodeCommand string
const (
	ANAdd AddNodeCommand = "add"
	ANRemove AddNodeCommand = "remove"
	ANOneTry AddNodeCommand = "onetry"
)
func (cmd AddNodeCommand) String() string {
	return string(cmd)
}
type FutureAddNodeResult chan *response
func (r FutureAddNodeResult) Receive() error {
	_, err := receiveFuture(r)
	return err
}
func (c *Client) AddNodeAsync(host string, command AddNodeCommand) FutureAddNodeResult {
	cmd := btcjson.NewAddNodeCmd(host, btcjson.AddNodeSubCmd(command))
	return c.sendCmd(cmd)
}
func (c *Client) AddNode(host string, command AddNodeCommand) error {
	return c.AddNodeAsync(host, command).Receive()
}
type FutureGetAddedNodeInfoResult chan *response
func (r FutureGetAddedNodeInfoResult) Receive() ([]btcjson.GetAddedNodeInfoResult, error) {
	res, err := receiveFuture(r)
	if err != nil {
		return nil, err
	}
	var nodeInfo []btcjson.GetAddedNodeInfoResult
	err = json.Unmarshal(res, &nodeInfo)
	if err != nil {
		return nil, err
	}
	return nodeInfo, nil
}
func (c *Client) GetAddedNodeInfoAsync(peer string) FutureGetAddedNodeInfoResult {
	cmd := btcjson.NewGetAddedNodeInfoCmd(true, &peer)
	return c.sendCmd(cmd)
}
func (c *Client) GetAddedNodeInfo(peer string) ([]btcjson.GetAddedNodeInfoResult, error) {
	return c.GetAddedNodeInfoAsync(peer).Receive()
}
type FutureGetAddedNodeInfoNoDNSResult chan *response
func (r FutureGetAddedNodeInfoNoDNSResult) Receive() ([]string, error) {
	res, err := receiveFuture(r)
	if err != nil {
		return nil, err
	}
	var nodes []string
	err = json.Unmarshal(res, &nodes)
	if err != nil {
		return nil, err
	}
	return nodes, nil
}
func (c *Client) GetAddedNodeInfoNoDNSAsync(peer string) FutureGetAddedNodeInfoNoDNSResult {
	cmd := btcjson.NewGetAddedNodeInfoCmd(false, &peer)
	return c.sendCmd(cmd)
}
func (c *Client) GetAddedNodeInfoNoDNS(peer string) ([]string, error) {
	return c.GetAddedNodeInfoNoDNSAsync(peer).Receive()
}
type FutureGetConnectionCountResult chan *response
func (r FutureGetConnectionCountResult) Receive() (int64, error) {
	res, err := receiveFuture(r)
	if err != nil {
		return 0, err
	}
	var count int64
	err = json.Unmarshal(res, &count)
	if err != nil {
		return 0, err
	}
	return count, nil
}
func (c *Client) GetConnectionCountAsync() FutureGetConnectionCountResult {
	cmd := btcjson.NewGetConnectionCountCmd()
	return c.sendCmd(cmd)
}