code: func New(dataDir string, lookupFunc func(string) ([]net.IP, error)) *AddrManager {
  	am := AddrManager{
  		peersFile:      filepath.Join(dataDir, "peers.json"),
  		lookupFunc:     lookupFunc,
  		rand:           rand.New(rand.NewSource(time.Now().UnixNano())),
  		quit:           make(chan struct{}),
  		localAddresses: make(map[string]*localAddress),
  		version:        serialisationVersion,
  	}
  	am.reset()
  	return &am
  }
docs: // New returns a new bitcoin address manager.
  // Use Start to begin processing asynchronous address updates.